Hello all,
I'm working on a XSL doc
1) which looks in XML-Doc1 to get an Xpath and this is assigned to a variable
assigns to a variable
my xml doc1 looks like this
<root>
<section id="1">
<type>text</type>
<xpath>//aaa/bbb/ccc</xpath>
</section>
...
...
...
</root>
so my xsl pick the data in<xpath> tag and stores it in a variable.
Further,
2) I need to get the data from XML-Doc2 based on the generated
xpath whch is stored in the variable.
my xml doc2 would look like
<aaa>
<bbb>
<ccc>10</ccc>
</bbb>
</aaa>
So I need to get value 10
and I am trying to use xpath_eval??? Is that right?? Is that the way to go....
I read about Saxom/Xalan etc but how do I go ahead with this problem in PHP.
While working wth just 1 XML doc(xml doc1) I used
$xsl = new XSLTProcessor();
$xsl->importStyleSheet(DOMDocument::load($xsl_filename));
echo $xsl->transformToXML(DOMDocument::load($xml_filename));
in PHP and it works fine.
How can I do this...???
Thanks in advance
Regards