Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
XALAN Processing error
sswamina2002
I have a CGI program which calls the xalan processor in the teamsite environment. Code extract is shown below.
"java org.apache.xalan.xslt.Process -IN $xmlFilePath -XSL $xslFilePath -OUT $outputFile -PARAM preview 1"
From Teamsite DCR's we generate the XML files. The CGI program is used to Transform the XML. The Transformation works correctly only if you are the owner of the DCR files. i.e If I create a new DCR and generate the XML, the transformation works correctly. If I am not the user who generated the XML from a DCR, the Transformation fails with an error code 65280.
Find more posts tagged with
Comments
pranav
Please provide Env. Details about teamsite ....
-Pranav
sswamina2002
We have Interwoven TeamSite 6.5.0 Service Pack 1.
It comes with Xalan2_6_0_XSLT_Parser.
imfarooq
How are you calling the CGI. Is it a menu item or a cgi callout?
Either way, are you passing yoru cgi thru iw-bin/iw_cgi_wrapper.cgi ?
If you do not pass it via the above wrapper cgi, the cgi will not get the
current user credentials (and other env variables).
syim
May I know how do you find out Xalan 2.6 is available in TeamSite 6.5 SP1. Do you know where I can find more information about invoking "java org.apache.xalan.xslt.Process" on TeamSite server. Seems my class path is not set correctly. However, I'm not sure here those related jar files for Xalan 2.6 are located on the TeamSite server.
Thanks
Johnny
Just incase you didn't know, you can use xslt (xalan) via formspublisher (TPL's).
If you can rely on the forms interface - all the classpath, ownership etc is handled for you.
John Cuiuli
Migrateduser
Dont know if I read your post correctly & how you are handling the XML file. I wil be surprised to see a permission issue there unless generated XML do not have even read permission for grooup/others (644 at minimum). May be you can try keeping 777 on the generated XML file before doing final transformation. You can always do everything in one shot in CGI or as John mentioned above is a better approach. Depends in the end what you are trying to do.
syim
Is there a more concret example on how to use tpl to parse output file with xslt? I followed the examples on
http://support.interwoven.com/library/devel/tst/pt/TeamSite__PT__iwov_xslt.html;
however, I got errors. Would it be something I did wrong?
Followings are what I have tried:
[demo.xml]
<?xml version="1.0"?>
<wow>Hello</wow>
[demo.xsl]
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="
http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:template match="wow">
<fun><xsl:value-of select="."/></fun>
</xsl:template>
</xsl:stylesheet>
[demo.tpl]
<?xml version="1.0" encoding="UTF-8"?>
<iw_pt>
<iwov_xslt xsl_file='demo.xsl' mode='cwd'>
<iw_include file='demo.xml' mode='cwd'/>
</iwov_xslt>
</iw_pt>
I put all 3 files into one common folder and issue following comman inside the folder:
iwpt_compile.ipl -pt demo.tpl -iw_include-location . -ofile out.xml
And I got following errors:
<ERROR>
iwov_xslt error:
XalanError:
XSL Warning: Fatal Error at (file /u02/apps/Interwoven/Teamsite/tmp/cci/tst_iwov_xslt_xml_22697, line 2, column 8): The XML or Text declaration must start at line/column 1/1
XSL Error: Could not parse /u02/apps/Interwoven/Teamsite/tmp/cci/tst_iwov_xslt_xml_22697 document!
XSL Warning: Unknown Exception
</ERROR>
Edited by syim on 07/19/05 10:51 AM (server time).