From: Bernhard W. <ber...@we...> - 2004-03-25 15:24:43
|
<html><style>p {margin: 0px}</style><body bgcolor='#ffffff' style='font-size:9pt; font-family:Verdana; font-family: Verdana' ><P>Hello Jonathan,</P><P>it will make no difference if I put the declaration of the $xslt variable within the for() loop. Unfortunately I have to process a lot of documents with different xsl files. I've tried as workaround the following code:</P><P>my $xslt = XML::XSLT->new ($xslurl, warnings => 1);<BR>for($i=0; $i<200; $i++) {<BR> $xslt->open_xsl($xslurl);<BR> $xslt->transform($xmlurl);<BR> print $xslt->toString;<BR>}<BR>$xslt->dispose();</P><P>But here I will get the error</P><P>Can't call method "getTagName" on an undefined value at C:/PERL/site/lib/XML/XSLT.pm line 869.</P><P>As I see </P><P>$template->getParentNode->getTagName</P><P>within __cache_templates will fail.</P><P>Thank you very much in advance for your help.</P><P>Best regards</P><P>Bernhard</P><P> </P><P><A href="mailto:gellyfish! @gellyfish.com">gel...@ge...</A> schrieb am 25.03.04 15:02:46:<BR>> The only thing I can think of is that you might want to move the lexical<BR>> declaration of the $xslt variable within your for() loop as this may<BR>> force the destruction of the xobjects. It might however be that we need<BR>> to dispose() of some of the XML::DOM xobjects that are created within<BR>> XML::XSLT. I'll check it out.<BR>> <BR>> /J<BR></P><br><br><table cellpadding="0" cellspacing="0" border="0"><tr><td bgcolor="#000000"><img src="http://img.web.de/p.gif" width="1" height="1" border="0" alt="" /></td></tr><tr><td style="font-family:verdana; font-size:12px; line-height:17px;">Der WEB.DE Virenschutz schuetzt Ihr Postfach vor dem Wurm Beagle.A-J! <br>Kostenfrei fuer FreeMail Nutzer. <A HREF="http://f.web.de/?mc=021158"><B>http://f.web.de/?mc=021158</B></A> </td></tr></table></body></html> |