I would like to transform any http/s based url inside random text to be automatically tagged with xsl-fo , where the random text might contains one or more http/s based url.
So the http/s url is not part of an attribute or the only content of a node, but part of text within a node.
For example: the source
<misc>
<comment>Yada..yada....
With my XSL code, whenever I delete an element .. It will introduce a blank-line-space in output xml .. which hampers the Tree-structure look of the XML .. Can you please suggest me .. How to get rid of it .. ?
Here are sample the sample codes ..
Sample XML:
<tag1>
<tag1_1>text</tag1_1>
<tag1_2 delete="Y">text</tag1_2>
<tag1_3>
...
Error message
(Location of error
unknown)org.apache.fop.fo.Validation
Exception: Property id "_Ref191196753"
previously used; id values must be
unique in document.
Any ideas on what may cause this? Is it because I have a for-each and apply the same template multiple times?
...
It has been a great challenge for me to code XSLT to bring my desired output ..
Here is my XML input .. which I am testing on ..
<aaa id="1">
<bbb id="2">text1</bbb>
<ccc>text2</ccc>
<ddd id="3">
<eee att="4d">text3</eee>
<fff>
<ggg att="3d">
<yyy>text4</yyy>
<iii attr="jj"/>
</ggg>
</fff>
...
Hi all,
I have a group of xsl sub stylesheets which i need to include into a parent stylesheet, all of which are contained in a directory below the parent. I have been using relative paths for the include statements however these now need to be changed full qualified paths.
As these all share the same directory it makes sense to do thi...
I am making a customer profile A how they are header and data about each visit.
I have gotten my data straight into one of many data objects PersonHeader ph, and StoreVisits sv:
oCustDetails = ActiveCustDetails.GetActiveCustDetails(custNumber, Convert.ToString(regionNumber));
ph.FirstName = oCustDetails.firstName;
ph.LastName ...
I am using Xalan and Java for extending a stylesheet.
(Similar example to what I am doing there : Dictionary example)
I struggle to make my tag do an <xsl:apply-templates/>. I wish to have this :
<xsl:template match="sometag">
<my-java:tag>
<xsl:apply-tempates/>
</my-java:tag>
</xsl:template>
My java class containing...
It seems that my template is never called but the for loop works correctly.
It prints "test" exactly the number of times the "car" node exists but "doStuff" doesn't seem to be accessed and "test2" is never outputted. Any ideas?
<fo:table-body>
<xsl:for-each select="car">
test
<xsl:apply-templates select="car" />
</xsl:f...
Hi there,
I have a set of items which i am grouping using the muenchian method using keys. This is working great however when i try to do things with the first x number of items it is doing it on the x number of items in each group rather than across the whole set of results. How would i get the individual position of each item accros...
I have the following XML data:
<?xml version="1.0" encoding="iso-8859-1"?>
<results>
<result>
<MemberFirstName>JOHN</MemberFirstName>
<MemberLastName>DOE</MemberLastName>
<MemberLogin>1</MemberLogin>
<Store>0180</Store>
</result>
<result>
<MemberFirstName>JANE</MemberFirstName>
<MemberLastName>D...
I would like ourside users to post videos, articles, audio, links and images. The users should be able to post the content then I approve or decline the content based on my own criteria. Users should be able to up/down vote articles, post comments and vote on the the comments. When someone views an article they should be able to see simi...
For historic reasons we have a mixture of
<xsl:output method="xml">
and
<xsl:output method="html">
and
<xsl:output method="xhtml">
inside an include-hierarchy of XSL files. Now we want to refactor so all XSL files use the same output method.
In the end we want to produce XHTML-output so I suppose the latter would be the best c...
I was researching alternatives to using Microsoft's XslCompiledTransform and everything seemed to point towards Saxon primarily and secondly XQSharp. As I started to look at documentation for Saxon I saw that XQuery could do the equivalent of my XSLTs that are no where near as terse as XQuery's markup is.
What advantages do XSLTs offer ...
when I output the value of the node directly for example:
<fo:inline><xsl:value-of select="isEnabled" /></fo:inline>
I get the correct string outputted in pdf "true"..
but if I set the value of isEnabled directly to a variable and then try to do the comparison on it.. it doesn't seem to work as if the node doesn't exist.
<xsl:vari...
I'm cleaning up some gross XML, and so I've had pretty_print = True set in the call to etree.tostring() on my lxml output of the XSL transform. However, that left me with a few junk whitespace nodes from the original input, so I added
<xsl:strip-space elements="*"/>
...but that completely collapses all whitespace, ignoring pretty prin...
Trying something kind of wacky in cleaning up some verbose XML, which is to remove all empty nodes recursively.
For this purpose, I consider a node to be "empty" if it has (a) no child nodes, (b) whitespace-only content, (c) only "empty" child nodes. That is, I consider the following to be "empty" because all of the leaves are empty/whi...
I am new to Stack Overflow and to XSLT. I have a problem with removing duplicate entries from the output, based on some child element conditions.
Here is an example of XML that I have:
<partyorders>
<order>
<day>12</day>
<month>05</month>
<year>2000</year>
<amount>5000.00</amount>
...
Hi,
I currently have an XML document like this:
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="./transform.xsl"?>
<Documentation><Tables>
<TABLE TABLE_NAME="FirstTable">
<COLUMN COLUMN_NAME="FirstColumn" ORDINAL_POSITION="1" IS_NULLABLE="NO" DATA_TYPE="int" />
<COLUMN COLUMN_NAME="SecondColumn" O...
Hi! I'm trying to learn XSLT (for some holiday coding fun). I think I now have a pretty good understanding of the basics (grabbing subtrees, filtering-out elements, and renaming elements). Where I'm having trouble is when it comes to drastically reorganizing XML structures. If you had a deeply nested structure and wanted to flatten it, h...
I have had a number of discussions recently over whether to use XSLT or code to write mapping functionality from one XML format to another or even when converting to something other than XML. Now I am of the mindset that XSLT's purpose is exactly for this type of thing and would be the most suitable option.
However, other people are su...