Questions tagged [apply-templates]

90 questions
0
votes
1 answer

xsl:apply-imports to a variable?

A.xsl imports B.xsl, which contains a function used in A.xsl. A.xsl contains the identity template. B.xsl's function needs to apply template rules to a variable; however, the identity template in A.xsl is overriding them. My thought was to…
wst
  • 11,681
  • 1
  • 24
  • 39
0
votes
1 answer

How does xsl:apply-templates work exactly and why does it write the name 2 times?

I am using http://www.freeformatter.com/xsl-transformer.html. Here is my XML document: Stanley Jordan
Ariel
  • 1,222
  • 2
  • 14
  • 25
0
votes
1 answer

XSLT Select using or?

I was wondering what the "|" in the apply template mean in XSLT. I am thinking that it pick…
Jack Thor
  • 1,554
  • 4
  • 24
  • 53
0
votes
2 answers

XSLT sort when using OR in select

Is there any way to get this to sort in the order of the select statement when it finds one or more PIDs?
Richard Tinkler
  • 1,635
  • 3
  • 21
  • 41
0
votes
1 answer

xsl:apply-templates with params - how to save formatting?

XSLT is used as a template engine. I have some structure of templates, which transfer data one from another with params:
safright
  • 127
  • 1
  • 5
0
votes
2 answers

XSLT multiple stylesheets

I have the following xml
user2263069
  • 15
  • 1
  • 3
0
votes
1 answer

passing parameter to parsing of imported file

In parsing a WSDL, I come across many wsdl:import and xsd:import elements. I would like to parse the imports and pass the @location or @schemaLocation to the parser. The intent is to have the file list grow when an imported file imports a file for…
bretter
  • 441
  • 7
  • 12
0
votes
1 answer

How to exclude child elements in xml?

I have the following xml : 203-555-1212 203-555-1212
12 Main Street
0
votes
1 answer

How to prevent a value being overwritten?

I’m having trouble transforming some elements of a XML message. I need to swap some values, but after I copied the the value of the last node to the first, I’m unable to reach the original value of the first node. I’ve been searching for hours and I…
mRope
  • 3
  • 1
0
votes
2 answers

XSLT - how to apply a template to every node of the type?

I am quite new to xsl and functional programming, so I'll be grateful for help on this one: I have a template that transforms some xml and provides an output. The problem is that there are many elements of type xs:date, all in different contexts,…
svz
  • 4,516
  • 11
  • 40
  • 66
0
votes
2 answers

XML and XSLT apply-templates select

Here's the XML file: Alexis Manager
shadowz1337
  • 710
  • 1
  • 8
  • 21
0
votes
2 answers

Calling xslt templates on elements generated inside the xslt

So I'm using the identity design pattern for XSLT: And I do have many templates matching different…
Knarf
  • 1,282
  • 3
  • 12
  • 31
-1
votes
1 answer

XSLT - using or in xsl:apply-templates

We have incoming JSON data from Source which has data and column in same payload. Using json-to-xml in XSLT I was able to generate XML like following:
-1
votes
1 answer

How to apply two templates to the same set of nodes, specifically all the nodes in a XML

I trying to create an output XML file from an input XML file. Some of the nodes need to be copied from input to output, some with be omitted, and a few of the nodes will have their text modified in some way. However in addition to this, I need to…
kel_ff0080
  • 759
  • 2
  • 6
  • 11
-1
votes
2 answers

XSL Links to pages

I'm a novice in XSL, so excuse me if my question is too easy. Look at code …
George Pirkulov
  • 83
  • 4
  • 11
1 2 3 4 5
6