Skip to main content

  | मौसम…

411 समाचार
Public archive edition · Attributed source reporting with original dates · AI drafts are excluded

411 REFERENCE · Wikibooks

XProc/Simple Pipe

Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.

Motivation You want to create a pipeline that runs a simple XSLT transform. Source Code <p:pipeline xmlns:p="http://www.w3.org/ns/xproc"> <p:xslt> <!-- Simple XML Source (inline) --> <p:input port="source"> <p:inline> <xml>Inline XML conversion with inline XSLT using XProc</xml> </p:inline> </p:input> <!-- XSLT Transform (inline) --> <p:input port="stylesheet"> <p:inline> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0"> <xsl:output method="xml" indent="yes" encoding="UTF-8" /> <!-- <xsl:output method="xhtml" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1- transitional.dtd" doctype-public="-//W3C//DTD XHTML 1.0 Transitional// EN" indent="yes" /> --> <xsl:template match="/xml"> <html> <head> <title>XSLT to XHTML via XProc</title> </head> <body> <h1> <xsl:value-of select="." /> </h1> </body> </html> </xsl:template> </xsl:stylesheet> </p:inline> </p:input> </p:xslt> </p:pipeline>