How to get a .php file XHTML validated successfully
<p>Can someone explain to me how to get a .php document that uses the shebang at the beginning of the file to pass the XHTML validator?  I keep getting one error that states that I have to put the xml utf-8 declaration at the beginning of the file.  When I do that I have to remove my shebang from line one.  As a result, the server cant read my document and I get an error.  For example the below file does not pass XHTML validation:</p>

<pre><code>#!/usr/local/bin/php

&lt;?= '&lt;' . '?xml version="1.0" encoding="utf-8"?' . '&gt;' ?&gt;

&lt;?php     

  $strLessonDescription = file_get_contents('http://example.com/.../lesson5.txt');

  if ($strLessonDescription  == NULL)
     print "Error - lesson5.txt cannot be opened";

  $arrLessonVocabulary = array();

  $arrLessonVocabulary = file("http://example.com/.../vocabulary5.txt");

  if ($arrLessonVocabulary == NULL)
     print "Error - vocabulary5.txt cannot be opened";  

?&gt;

  &lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0       Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"&gt;
  &lt;html xmlns="http://www.w3.org/1999/xhtml" &gt;
</code></pre>
