Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to write XML DTD in PHP 2

Status
Not open for further replies.

soundmind

Technical User
Jun 30, 2003
16
US
Hello!

I wrote an application to generate webpages using PHP based on the content stored in a database.

In the first part of the webpage should write:

<? xml version='1.0' encoding='UTF-8' ?>

But since it starts with the PHP <? ?>, it's causing some problems.

Would a normal escape for these characters work? Or do I need to do something special to write these out?

Thanks in advance!
 
use
echo &quot;<? xml version='1.0' encoding='UTF-8' ?>\n&quot;; and it works.
PHP will ignore &quot;?>&quot; if its inside quotes of an echo (or anything else for that matter.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top