File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

scope of XSL ?

 
Priyadarshini Anand
Greenhorn
Posts: 22
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello ,


Hello,

I am new in XML & XSL.I have a problem in my project.The simplified form of my problem is :

If there is a directory "A" containing A.xml, I need to display it using XSL.I want to display all the subdirectories and files in "A".How will i write XSl.Is it possible in XSL.I need urgent help.Thanks,

Priya

if u understood above proble pl have a look below :


exact problem is as follows ::



I have a XML file in a directory 'A' displayed by XSL file.Now, this XSL file should be capable of

1. displaying the name of all the subdirectories of A that contain a xml file with the same name as the subdirectory has.
2. displaying all the XML files in directory A that contain node<passcount> and <failcount> anywhere in XML.

How should i approach,document() function should help but i am not geting how to use it in this case.pl help me.

[ June 10, 2004: Message edited by: Priyadarshini Anand ]
[ June 10, 2004: Message edited by: Priyadarshini Anand ]
 
Balaji Loganathan
author and deputy
Bartender
Posts: 3150
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Priyadarshini Anand:
Hello ,
If there is a directory "A" containing A.xml, I need to display it using XSL.I want to display all the subdirectories and files in "A".

If i understood correctly, do you want to
1.Retrieve the list of XML files in the directory "A"
2.Display each XML file with XSL using XSL.???
XSLT is not meant for accessing the local system details, or its not possible with XSL to access the directory and list down the xml files for furhter processing. Not a good approach/idea.
Having said that, both XALAN-j and XT for java have extension funtion which allow you to do java related method calls. For example you can display date/time in XSL using the extension feature of Xalan-j.
 
Priyadarshini Anand
Greenhorn
Posts: 22
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, for the information.What I need to study to achieve the purpose i want to solve? How to integrate java &XSl & XML.Some online material..topics specifically for the problem ???

Thanks Priya
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Priyadarshini Anand:
How to integrate java &XSl & XML.

http://www.javaalmanac.com/egs/javax.xml.transform/BasicXsl.html
 
Arun Prasath
Ranch Hand
Posts: 192
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For displaying the subdirectories in a specific folder, you can use java to find the set of folders and pass them as a parameter to xsl processor (Xalan or Saxon). Both the processors has "extensions" feature which you can use it.
This URL might help.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic