Forums Register Login

apply- templates!!!!!!!!

+Pie Number of slices to send: Send
Hi there,
Acc. to nutshell apply-templates changes the order of traversal.
If we want to select a certain elts we can use that.
But what exactly <apply-templates /> does?
Can anyone explain me with an example?
Thanks in advance,
Shakthy
+Pie Number of slices to send: Send
Sorry i missed XSL
what exactly It represent
<xsl:apply-templates/>
thanks
+Pie Number of slices to send: Send
It means "for each child of this node, try to find and apply an appropriate matching template".
+Pie Number of slices to send: Send
I guess you can also look at it this way. Since the select is not explicitly mentioned, the default value will be used, which will be the child axis and hence we are in effect apply-templates to all the children of the current context node.
+Pie Number of slices to send: Send
Thanks for the clarification!
Yet i need to work our some examples on that.
I have another problem running the Xalan processor. I extract the jar files & did the classpath settings.
Everything is perfect .
But once run i try ot run Fitness.xml file it says JRE files not found in the correct directory missing rt.jar;
But iam having my JRE file in c:/programfiles/.../rt.jar; I did set the classpath what do i have to do next.
Plz help me with these Issues i couldnt work out some examples or clear my doubts.
Thanks.
+Pie Number of slices to send: Send
Hi Jayadev,
In this below link u posted some solution Iam not clear could u plz explain me step by step.
I am having the same error like paula.
"Jre not installed in the correct dir"
https://coderanch.com/t/146822/po/certification/running-XSLT-program
Thanks
Shakthy
+Pie Number of slices to send: Send
Try to have your JRE/bin in the system path and the place where you have the class files in the CLASSPATH. I think if you have .jar files, you need to mention the filenames explicitly in the classpath. Just mentioning the directory where you have the jar files is not going to be sufficient.
Hope this helps.
+Pie Number of slices to send: Send
Hi Jayadev,
Is this correct :
c:/jdk/bin;
c:/jdk/jre1.1.3/lib/rt.jar;<!-- Java classpath)
c:/xalan/xalan/bin;c:/xalan/xalan/bin/xalan.jar;
<!-- xalan processor -->
I appreciate ur help,
+Pie Number of slices to send: Send
I really don't know how to interpret this message. ""Jre not installed in the correct dir"". May be someone else who faced a similar problem should be able to help you. Sorry for not being of much help.
+Pie Number of slices to send: Send
Hi Jayadev,
That's ok! Is there any way i can run XSLT programs?I think saxon is also based on Java.
I have some other questions!
Could u plz help me with that!
13. Which of the following XML fragments are well-formed?
a)<myElement myAttribute="value1 <= value2"/>
b)<myElement myAttribute="value1 & value2"/>
c)<myElement myAttribute="value1 > value2"/>
d)<myElement myAttribute="value1'value2"/>

Answers: c d
Well-formed XML document is not allowed to use "<" and "&" characters within an attribute value

My answer : D
What abt ">" ?
Correct me if iam wrong!

2.From skillometer.com
<!xml version="1.0">
<person>
<name>
<fname>some info</fname>
<lname>someother info</lname>
</name>
<address>info1</address>
<phone>info2</phone>
</person>
1.valid
2.valid & wellformed
3.invalid & not wellformed
4.wellformed
Up to my knowledge,The given example is wellformed.?
What if there is no DTD or schema to check the validity But the Xml doc is wellformed
Which option do i have to check there?
Thanks in advance
Shakthy.
+Pie Number of slices to send: Send
">" is allowed in an attribute value. I don't know why, but it is.
An XML file cannot be "valid" if there is no DTD or schema to validate it against.
+Pie Number of slices to send: Send
Sorry the first line of that program is here :
<?xml version="1.0"?>
Replace this:
I got confused with another Document.
Thanks,
Shakthy
Hug your destiny! And hug this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 1015 times.
Similar Threads
recursion and apply-templates
QA Engineer@ DC Area Energy Efficiency Startup
Intermediate Java Developer - Confidential, Montreal, Canada
XSLT - Help
RAD 6 , Preference file
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 03:47:55.