Answered
Passing PHP variables to $mm_xls->setXML statement
Ugh! need some help
I am attempting to modify the $mm_xls->setXML line below to accept
a passed variable. The line works fine with a fixed path as shown below.
$mm_xsl->setXML("../xml_files/097.xml");
When I attempt to replace ------"../xml_files/097.xml"-----
with a passed variable -- noluck.
Below is one attempt, the passed variable is $colname_rs_for_gallery.
The $test_var works and yields the proper result, but it along with many
other variations don't seem to work in the $mm_xls->setXML statement.
Do I need different punctiontuation to correct the syntax?
<?php ---this was just a test segment---
$test_var='"../xml_files/'.$colname_rs_for_gallery.'.xml"';
echo $test_var;
?> --- the echo produced by the above "../xml_files/097.xml" which is what I wanted.
<?php
$mm_xsl = new MM_XSLTransform();
$mm_xsl->setXML(echo $test_var;); ------This is the line in question---
$mm_xsl->setXSL("../xml_files/gallery_fragment.xsl");
echo $mm_xsl->Transform();
Thanks Phil Fisher
I am attempting to modify the $mm_xls->setXML line below to accept
a passed variable. The line works fine with a fixed path as shown below.
$mm_xsl->setXML("../xml_files/097.xml");
When I attempt to replace ------"../xml_files/097.xml"-----
with a passed variable -- noluck.
Below is one attempt, the passed variable is $colname_rs_for_gallery.
The $test_var works and yields the proper result, but it along with many
other variations don't seem to work in the $mm_xls->setXML statement.
Do I need different punctiontuation to correct the syntax?
<?php ---this was just a test segment---
$test_var='"../xml_files/'.$colname_rs_for_gallery.'.xml"';
echo $test_var;
?> --- the echo produced by the above "../xml_files/097.xml" which is what I wanted.
<?php
$mm_xsl = new MM_XSLTransform();
$mm_xsl->setXML(echo $test_var;); ------This is the line in question---
$mm_xsl->setXSL("../xml_files/gallery_fragment.xsl");
echo $mm_xsl->Transform();
Thanks Phil Fisher
