Skip to content

Instantly share code, notes, and snippets.

black pony

Mathias mathias-goebel

black pony
View GitHub Profile
View register.html
to be placed in /[PROJECTS]/[PROJECT-NAME]/templates/tmpl1/
requires: module and sign-up.html
<div data-template="templates:init">
<div data-template="templates:surround" data-template-with="page_index.html" data-template-at="content-container">
<div data-template="usr:new"/>
mathias-goebel / final.xsl
Last active Aug 29, 2015
sort zones with xslt
View final.xsl
<?xml version="1.0" encoding="UTF-8"?>
<!-- Stylesheet imporved by hriebl! -->
exclude-result-prefixes="xs tei"
<xsl:output method="xml" indent="yes" />
View selected XQuery snippets
several useful XQuery snippets, mainly used with eXist-db
mathias-goebel / list.html
Last active Aug 29, 2015
Queries on "TextGrid Digitale Bibliothek"
View list.html
<!DOCTYPE html>
<title>TG Rep - Publikationsliste</title>
<li>Bierbaum, Otto Julius  Stilpe. Ein Roman aus der Froschperspektive 
(1865 - 1910)</li>
View WikipediaCategory2KML.xql
xquery version "3.0";
import module namespace console="" at "java:org.exist.console.xquery.ConsoleModule";
declare namespace rdfs="";
declare namespace ps="";
declare namespace wdt="";
declare namespace rdf="";
declare option exist:serialize "method=xhtml media-type=application/ highlight-matches=none";
mathias-goebel / TEI-JSON.xq
Created Mar 8, 2016
sunburst tree for TEI data
View TEI-JSON.xq
xquery version "3.0";
declare namespace tei="";
declare option exist:serialize "method=text media-type=text/plain omit-xml-declaration=yes";
declare function local:recurse($node as node()*) as xs:string* {
for $n in $node
'{' ||
('"name": "', $n/local-name(), '"',
if( not($n/*) )
View MainArtists.xq
xquery version "3.0";
let $url := xs:anyURI(''),
$persist:= false(),
$request-headers := (),
$node as node() := httpclient:get($url, $persist, $request-headers)//httpclient:body/*,
$origList := tokenize(
$node//*[contains(@class, 'paper_author')]/
mathias-goebel / lb-handling.xquery
Created May 18, 2016
TEI:lb and other empty elements in XQuery
View lb-handling.xquery
xquery version "3.0";
declare namespace tei="";
declare function local:magic($nodes as node()*) {
(:let $test:= console:log($nodes/local-name()):)
for $node in $nodes return
case element(*)
mathias-goebel / query.xq
Created May 30, 2016
TextGrid Agg Names
View query.xq
xquery version "3.0";
declare namespace ore="";
declare namespace rdf="";
declare namespace tgmd="";
let $seq:= ("textgrid:jfsm.0",
mathias-goebel / TextGrid-CRUD.xq
Created Oct 7, 2016
Store nodes in the TextGrid Repository
View TextGrid-CRUD.xq
xquery version "3.0";
declare namespace tei="";
(: TextGrid CRUD
: Store nodes in the TextGrid Repository
: :)
(: ESX-2 = productive :)