Skip to content

Instantly share code, notes, and snippets.

View eedeebee's full-sized avatar

Eric Bloch eedeebee

  • Hillsborough, CA
View GitHub Profile
<page display="Code" href="/code">
<group display="Open Source Projects">
      <group display="Applications">
        <page display="Authoring App for Word" href="/code/marklogic-sample-authoring"/>
        <page display="AtomPub Server" href="/code/atompub-server"/>
        <page display="XFaqtor" href="/code/xfaqtor"/>
        <page display="Shakespeare Demo Application" href="/code/bill"/>
        <page display="xqlog: XQuery Blogger" href="/code/xqlog"/>
        <page display="RunDMC" href="/code/rundmc"/>
<para>{
for $x in $p/node() return (if ($x/self::emphasis)
then <em>{$x/node()}</em>
else $x)
}</para>
<para>{
for $x in $p/node() return (if ($x/self::emphasis) then <em>{$x/node()}</em>
else if ($x/self::bold) then <strong>{$x/node()}</strong>
else $x)
}</para>
xquery version "1.0-ml";
declare default element namespace "http://www.w3.org/1999/xhtml";
(: This function takes the children of the node and passes them
back into the typeswitch function. :)
declare function local:passthru($x as node()) as node()*
{
for $z in $x/node() return local:dispatch($z)
};
xquery version "1.0-ml";
declare default element namespace "http://www.w3.org/1999/xhtml";
let $xslt :=
<xsl:stylesheet version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xpath-default-namespace="http://www.w3.org/1999/xhtml">
<xsl:template match="title">
<h1>
<xsl:template match="numbered">
<ol>
<xsl:apply-templates/>
</ol>
</xsl:template>
<xsl:copy-of select="xdmp:invoke('twitter.xqy')"/>
<xdmp:import-module href="/model/data-access.xqy"
namespace="http://developer.marklogic.com/site/internal"/>
<xsl:variable name="comments-for-post"
select="ml:comments-for-post(base-uri(.))"/>
xquery version "1.0-ml";
(: Copyright 2002-2010 Mark Logic Corporation. All Rights Reserved. :)
declare namespace feed = "http://marklogic.com/extension/plugin/feed";
import module namespace plugin = "http://marklogic.com/extension/plugin" at "/MarkLogic/plugin/plugin.xqy";
import module namespace info="http://marklogic.com/appservices/infostudio" at "/MarkLogic/appservices/infostudio/info.xqy";
import module namespace infodev="http://marklogic.com/appservices/infostudio/dev" at "/MarkLogic/appservices/infostudio/infodev.xqy";