RE: [PHP] XHTML and PHP

From: Date: Sat, 29 Sep 2001 18:13:24 +0000
Subject: RE: [PHP] XHTML and PHP
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-69306@lists.php.net to get a copy of this message
That approach doesn't work. It treats the string literally and prints: <? echo("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"); ?> in the HTML. Thanks for trying to help... Navid -----Original Message----- From: David Otton [mailto:djo@jawbone.freeserve.co.uk] Sent: Saturday, September 29, 2001 7:31 AM To: Navid Yar Cc: php-general@lists.php.net Subject: Re: [PHP] XHTML and PHP On Sat, 29 Sep 2001 02:35:24 -0500, you wrote: >Hello intelligent folks... > >I have a problem with XHTML and PHP > >The first line of an XHTML document must include an XML processing >instruction, as such: ><?xml version="1.0" encoding="UTF-8"?> > >But PHP will parse it as PHP code because of the question marks. How do I >get around this problem? I don't want PHP to read that element as PHP, I >want it to leave it alone the way it is. I tried echoing the tag and Put this on the first line of your script : <? echo("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"); ?> djo

« previous php.general (#69306) next »