rf-web/vendor/bundle/gems/rouge-3.12.0/lib/rouge/demos/xquery

23 lines
574 B
Plaintext
Raw Normal View History

2019-10-21 08:18:17 +00:00
declare namespace html = "http://www.w3.org/1999/xhtml";
declare function local:test-function($catalog as document-node()) {
<html>
<head>
<title>XQuery example for the Rouge highlighter</title>
<link href="style.css"/>
</head>
<body>
<h1>List</h1>
<ul>
{for $product in $catalog/items/product[@sell-by > current-date()] return
<li>
<ul>
<li>{data($product/name)}</li>
<li>{$product/price * (1 + $product/tax)}$</li>
</ul>
</li>}
</ul>
</body>
</html>
};