I have an XSL-FO stylesheet that is used for generating a barcode with a piece of description text immediately after it. When I run it through the Ibex FO application, the text properly lines up with the bottom of the barcode. When I run it through Apache FOP (it's an older version 0.3x... I CAN'T change this), the text lines up with t...
In my application I am using the 4Suite.org XSLT library to perform transformations of source XML. The syntax is like this:
from Ft.Xml.Xslt import Transform
transformed_xml = Transform(raw_xml, stylesheet)
where raw_xml and stylesheet have been defined elsewhere in my application. raw_xml will be the xml resulting from reading a fi...
Is it possible to add text from a xsl variable to the inside of a html tag something like this?
<xsl:variable name="selected">
<xsl:if test="@class = 'selected'"> class="selected"</xsl:if>
</xsl:variable>
<li{$selected}></li>
...
I am using xsl to transform a xml to html. A table is created in the html but some problem of the unduplicated items appear.
If I use a unique key to form the table(xsl for-each of every row), for example, context, but this attribute is not in the table.
the final table is like this
context(invisible) attr1 attr2 attr3
1 ...
I have a loop with the same tags to load content in ten cells but has a difference div title and background image, so I wonder is there any way to use the switch case just to put correct div title when I do for-each to load content for each cells in XSL?
something like this:
<...load the same tags content here...>
Please help me be...
I am editing an XSLT template and my skills are a little rusty.
I would like to write a condition to see if the current node is in the first three child nodes of its parent.
<parent>
<child>
<child>
<child>
<child>
</parent>
So the first three child elements above would return true, but the fourth would return false, to complicat...
I'm creating a template which produces output based on a single string, passed via parameter, and does not use an input XML document. xsltproc seems to happily run with a single parameter specifying the stylesheet, but I don't see a way to trigger a template without an input file (no parameter to xsltproc to run a named template, for ex...
We have an application which has a heirarchical group structure. Some of the groups are passed in this format:
/Geography/NA/US/California
I would like to "unroll" this string so that I can get a node set like the following:
/Geography
/Geography/NA
/Geography/NA/US
/Geography/NA/US/California
I know I can use str:tokenize and get ...
I try to use upper-case() in an XPATH, my parser is MSXML 4.0, and I get :
upper-case is not a valid XSLT or XPath function.
Is it really not implemented ?
...
Thank you one and all.
I have an PHP MVC framework that uses XSLT for the templates. I have registered some php functions with the template to allow the use of modules in the template. This allows us to call modules at need be instead of running all the modules first regardless if you need them all.
The problem is the fact some (most, ...
I have a source document:
<?xml version="1.0"?>
<source>
<ItemNotSubstituted/>
<ItemToBeSubstituted Id='MatchId' />
</source>
And a stylesheet containing content I want to substitute into the source:
<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output indent="yes"...
(N.B.: Yes, this is a ridiculous question, and I will be entirely unsurprised if the answer to this question is "no". That said:)
I've written an XSLT stylesheet which deliberately performs a lengthy, unparallelizable computation on an XML fragment. It's intended as a component of a proof-of-work system to be used in a web browser as a ...
So here is my current code:
<xsl:variable name="address">
<xsl:value-of select="concat(/node1/node2/address.node/street, /node1/node2/address.node/city, /node1/node2/address.node/zip)" />
</xsl:variable>
Now, I'm trying to shorten this down to:
<xsl:variable name="addressNode">
<xsl:value-of select="/node1/node2/address.node"...
I don't know if it's possible, but I'm wondering how to do it...
Let's say we have the following XSL:
<xsl:template name="foo">
Bla bla bla
</xsl:template>
...
<xsl:template name="bar">
Bla bla bla
</xsl:template>
...
<xsl:template match="/">
<xsl:if test="$templateName='foo'">
<xsl:call-template name="foo"/>
</xsl:if>
<x...
I'm trying to load an xml from a url in C#, but the problem is that, there is an xsl attached to the xml file, which means that I don't get the content of the xml file, but the html that it's transformed to using the xsl.
Is there any way to load the xml without first transforming it, so I just get the content of the xml?
...
Part of the XML:
<text><b>Title</b> <b>Happy</b></text>
In my XSL I have:
<xsl:value-of select="text" disable-output-escaping="yes" />
My output becomes
**TitleHappy**
My spacing went missing - there's supposed to be a space between </b> and <b>.
I tried normalize-space(), it doesn't work.
Any suggestions? Thanks!
...
I have XML in the following format:
<Order>
<Customer>
<Name>kapil</name>
<AddressLine1>ABC</AddressLine1>
<PostCode>12345</postCode>
</Customer>
<Customer>
<Name>Soniya</name>
<AddressLine1>XYZPER</AddressLine1>
<PostCode>54321</postCode>
</Customer>
<Customer>
<Name>kapil</name>
<Addre...
Hi i am having the xml file as:
<order><Extension Properties><Date>2009-08-04T17:09:04.593+05:30</Date></Extension Properties></Order>
and i want the output as
Generation Date 040809
I want to do this via xslt.Please help..!!
...
hi friends
I am getting a particular value by using
<xsl:value-of select="@date" />
and i want to store this value as a variable say 'd'
How can i do this and also tell me how can i use that caribale back in my template.
Thanks in advance
...
Hi friends...I am having a lot of problem. I need the solution very urgent..please help me
So i am having a xml file as:
<Order>
<EP>
<Name>Generation Date</Name>
<Value>2009-08-04+05:30</Value>
</EP>
<EP>
<Name>NoOfRecords</Name>
<Value>100</Value>
</EP>
<OrderLineItems>
<OrderLineItem OrderDateTime="2007-01-01T17:0...