[xslt] HTTP header problem: xsltproc from PHP/Windows



I am not sure whether this is specific to the Windows version of xsltproc, but when executed from the command line it does not cause the command prompt to wait until it completes.  But, it still outputs information to the command prompt from which it was executed.  For one thing, this means that it’s rather hard to determine whether the process has really completed, because either way you’ll still get a blinking cursor that you can type into.

 

This behavior, although I am guessing it is by design, is causing me problems when trying to execute xsltproc from PHP.  I can post around on PHP areas, but I figured I would ask you guys first.  The problem is that unless I run xsltproc with the Windows command-line command “start /b”, it causes the PHP script to behave strangely echoing:

 

CGI Error

The specified CGI application misbehaved by not returning a complete set of HTTP headers.

 

So, I could run xsltproc with the “start” command, but if I do that I can’t get the result code that xsltproc returns because start returns 0 regardless.

 

I am basically using the PHP statement:

exec('xsltproc.exe', $output, $return);

 

Hopefully someone will have a suggestion!  Thanks for taking a look.

And also, thanks to the developers of libxml, it’s supporting packages, and the guy who did the windows port!

 

-Shannon



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]