<?xml version="1.0" encoding="utf-8"?>
<seller id="000364">
<order number="00060310">
<customername>Metropolis Real Estate</customername>
<shipto>
<address1>100 Main St</address1>
<address2>></address2>
<city>Metropolis</city>
<state>OH</state>
<zip_code>45416</zip_code>
</shipto>
<item number="001">
<printfile>http://www.metropolishomeexperts.com/brochures/br096.pdf</printfile>
<quantity>10</quantity>
</item>
<item number="002">
<printfile>http://www.metropolishomeexperts.com/posters/po014.pdf</printfile>
<quantity>5</quantity>
</item>
<item number="003">
<stock number="mug036"></stock>
<quantity>5</quantity>
</item>
</order>
<order number="00060311">
<customername>Town Point Realty</customername>
<shipto>
<address1>450 Broadway</address1>
<address2>Suite 12</address2>
<city>Parkview</city>
<state>IL</state>
<zip_code>60404</zip_code>
</shipto>
<item number="001">
<printfile>http://http://www.townpointrealty.com/print/0196.pdf</printfile>
<quantity>20</quantity>
</item>
<item number="002">
<stock number="cap0342"></stock>
<quantity>10</quantity>
</item>
</order>
</seller>
/seller/order
Order number 00060310
<?xml version="1.0" encoding="UTF-8"?>
<order number="00060310">
<customername>Metropolis Real Estate</customername>
<shipto>
<address1>100 Main St</address1>
<address2>></address2>
<city>Metropolis</city>
<state>OH</state>
<zip_code>45416</zip_code>
</shipto>
<item number="001">
<printfile>http://www.metropolishomeexperts.com/brochures/br096.pdf</printfile>
<quantity>10</quantity>
</item>
<item number="002">
<printfile>http://www.metropolishomeexperts.com/posters/po014.pdf</printfile>
<quantity>5</quantity>
</item>
<item number="003">
<stock number="mug036"/>
<quantity>5</quantity>
</item>
</order>
Order number 00060311
<?xml version="1.0" encoding="UTF-8"?>
<order number="00060311">
<customername>Town Point Realty</customername>
<shipto>
<address1>450 Broadway</address1>
<address2>Suite 12</address2>
<city>Parkview</city>
<state>IL</state>
<zip_code>60404</zip_code>
</shipto>
<item number="001">
<printfile>http://www.impactonthenet.com/buildsales.pdf</printfile>
<quantity>20</quantity>
</item>
<item number="002">
<stock number="cap0342"/>
<quantity>10</quantity>
</item>
</order>
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" exclude-result-prefixes="xs">
<xsl:output method="text" encoding="UTF-8"/>
<xsl:template match="/">
<xsl:variable name="var1_initial" select="."/>
<xsl:for-each select="order">
<xsl:variable name="var2_current" select="."/>
<xsl:value-of select="concat('Job.Info.Attr1=', @number, ' ', 'Job.CustomerName=', customername)"/>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
Order number 00060310
Job.Info.Attr1=00060310Job.CustomerName=Metropolis Real Estate
Order number 00060311
Job.Info.Attr1=00060311Job.CustomerName=Town Point Realty
/order/item/printfile/ancestor::item
When the XML input file contains order number 00060310, Ricoh ProcessDirector creates these XML files.
Item 001
<?xml version="1.0" encoding="utf-8"?>
<item number="001">
<printfile>http://www.metropolishomeexperts.com/brochures/br096.pdf</printfile>
<quantity>10</quantity>
</item>
Item 002
<?xml version="1.0" encoding="utf-8"?>
<item number="002">
<printfile>http://www.metropolishomeexperts.com/posters/po014.pdf</printfile>
<quantity>5</quantity>
</item>
/order/item/stock/ancestor::item
When the XML input file contains order number 00060310, Ricoh ProcessDirector creates this XML file.
<?xml version="1.0" encoding="utf-8"?>
<item number="003">
<stock number="mug036"/>
<quantity>5</quantity>
</item>
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" exclude-result-prefixes="xs">
<xsl:output method="text" encoding="UTF-8"/>
<xsl:template match="/">
<xsl:variable name="var1_initial" select="."/>
<xsl:for-each select="item">
<xsl:variable name="var2_current" select="."/>
<xsl:value-of select="concat('Job.DownloadFile=', printfile, ' ', 'Job.Copies=', quantity)"/>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
Item 001
Job.DownloadFile=http://www.metropolishomeexperts.com/brochures/br096.pdfJob.Copies=10
Item 002
Job.DownloadFile=http://www.metropolishomeexperts.com/posters/po014.pdfJob.Copies=5
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" exclude-result-prefixes="xs">
<xsl:output method="text" encoding="UTF-8"/>
<xsl:template match="/">
<xsl:variable name="var1_initial" select="."/>
<xsl:for-each select="item">
<xsl:variable name="var2_current" select="."/>
<xsl:value-of select="concat('Job.Info.Attr2=', stock/@number, ' ', 'Job.Copies=', quantity)"/>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
Job.Info.Attr2=mug036Job.Copies=5