{if ($lang = 'ru') then 'Карта' else 'Map'}
module namespace map = 'http://ossetic-studies.org/ns/abaevdict-site/map';
import module namespace abv-m = 'http://ossetic-studies.org/ns/abaevdict-mod' at '../../abv-mod.xqm';
declare %rest:path("{$lang}/map")
%rest:query-param("entry", "{$entry}")
%rest:GET
%rest:produces("text/html")
%output:method("html")
%output:html-version('5')
function map:map($lang as xs:string, $entry as xs:string) {
let $mapdata := abv-m:make-geomap(
doc(`abaevdict_{$lang}/xml/{$entry}.xml`),
$lang)
return
( {if ($lang = 'ru') then 'Карта' else 'Map'}