Little Goat Posted May 6, 2006 Share Posted May 6, 2006 Hi, yet another question from someone learning PHPhow do you get around the php thinking that the xml declaration is a php section? LG Link to comment Share on other sites More sharing options...
skym Posted May 7, 2006 Share Posted May 7, 2006 Disable the short_open_tag setting in the php.ini file, or put this in the .htaccess file:php_flag short_open_tag off( btw, hello everybody, this is my 1st post in this forum ) Link to comment Share on other sites More sharing options...
Jack McKalling Posted May 7, 2006 Share Posted May 7, 2006 (edited) No there is an easyer way :)I have the perfect sollution :)JUST ECHO IT LOL <?phpecho "<?xml blabla ?>";?> Edited May 7, 2006 by Dan The Prof Link to comment Share on other sites More sharing options...
skym Posted May 7, 2006 Share Posted May 7, 2006 Right, the echo might resolve the problem, but I wonder how did he get into this sort of problem. So I gave the ini file setting answer, just in case. Link to comment Share on other sites More sharing options...
Jack McKalling Posted May 7, 2006 Share Posted May 7, 2006 I got it too.It occurs when the file is a php-file, and the output is supposed to be Xhtml. It requires the xml declaration, and it starts the same as php-tags, so you should php override the tag and let it print it instead Link to comment Share on other sites More sharing options...
Little Goat Posted May 8, 2006 Author Share Posted May 8, 2006 ok, thanks guys.I wanted my php to output valid XHTML like you said Dan.the echo sounds good. thanx again.LG Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now