出现内部错误

I am trying to do the final table in the lab but every time I try to view the file on Firefox it says I get an internal error.

The code is as follows:

<!DOCTYPE html>
<!--
    Author:Randy Gilman
-->
<!--Table two-->

<html>
    <head>
    </head>
    <body>
    <table border="1" cellpadding="10">

    <tr>
        <th>
        <?php 
 $x = 1;
 $y = 0;

  while($x <= 1) {
      echo "$x ";
      $x++;
  } 
 ?>
  <br>
 <?php
  while($x <= 2) {
      echo "$y ";
      $y++;
  } 
 ?> 
        </th>
        <th>  
        </th>
    </tr>
    <tr>
        <th>
        </th>
        <th>           
        </th>
    </tr>

       </table>
       </body>
<!--End of table two-->
</html>

Every other program I have saved works. I try to rename it copy and paste to a new document but it will not let me do it. So I am thinking its the code but it was working earlier but now nothing. Usually if the code is bad it will just be a blank screen but with this it freezes up the system. Any help would be appreciated.

Fixed the infinite loop but I get this now:

enter image description here

I'm not certain, but this could be an issue. This loop would never stop ...

<?php
  while($x <= 2) {
      echo "$y ";
      $y++;
  } 
 ?> 

Should be while ($y <= 2), right?

In second while loop you have a typo, causing infinite loop.
Change it in this way:

while( $y <= 2 ) {
    echo "$y ";
    $y++;
} 

Also please note that the <title> tag is mandatory in html 5.