diff -cr --exclude=*.txt --exclude=*.diff phorum306/phorum306/common.inc phorum307/phorum307/common.inc
*** phorum306/phorum306/common.inc	Thu Sep 16 11:56:32 1999
--- phorum307/phorum307/common.inc	Thu Oct 21 09:52:30 1999
***************
*** 21,27 ****
  
    error_reporting(1023); 
  
!   $phorumver="3.0.6";  
  
    function undo_htmlspecialchars($string){
  
--- 21,27 ----
  
    error_reporting(1023); 
  
!   $phorumver="3.0.7";
  
    function undo_htmlspecialchars($string){
  
diff -cr --exclude=*.txt --exclude=*.diff phorum306/phorum306/form.inc phorum307/phorum307/form.inc
*** phorum306/phorum306/form.inc	Mon Sep 13 13:09:20 1999
--- phorum307/phorum307/form.inc	Thu Oct 21 09:43:42 1999
***************
*** 68,74 ****
      echo "<p><b>$IsError</b>";
    }
  ?>
! <form action="<?PHP echo "$post_page.$ext"; ?>" method="POST">
  <input type="Hidden" name="thread" value="<?PHP  echo $thread; ?>">
  <input type="Hidden" name="action" value="post">
  <input type="Hidden" name="num" value="<?PHP echo $num; ?>">
--- 68,74 ----
      echo "<p><b>$IsError</b>";
    }
  ?>
! <form action="<?PHP echo "$post_page.$ext"; ?>" method="post" enctype="multipart/form-data">
  <input type="Hidden" name="thread" value="<?PHP  echo $thread; ?>">
  <input type="Hidden" name="action" value="post">
  <input type="Hidden" name="num" value="<?PHP echo $num; ?>">
***************
*** 103,109 ****
      <td <?PHP echo bgcolor($TableBodyColor1); ?> colspan=2 width="100%" nowrap align="left"><table cellpadding="5" cellspacing="0" border="0"><tr><td align="CENTER" valign="TOP"><textarea name="body" cols="45" rows="20" wrap="VIRTUAL"><?PHP echo $p_body; ?></textarea></td></tr></table></td>
  </tr>
  <tr>
!     <td <?PHP echo bgcolor($TableBodyColor1); ?> colspan=2 width="100%" nowrap align="left"><input type="checkbox" name="email_reply" value="Y"><?PHP echo $lEmailMe; ?></td>
  </tr>
  <tr>
      <td width="100%" colspan="2" align="RIGHT" <?PHP echo bgcolor($TableBodyColor1); ?>><?PHP echo $quote_button; ?>&nbsp;<input type="Submit" name="post" value=" <?PHP echo $lFormPost;?> ">&nbsp;<br><img src="images/trans.gif" width=3 height=3 border=0></td>
--- 103,109 ----
      <td <?PHP echo bgcolor($TableBodyColor1); ?> colspan=2 width="100%" nowrap align="left"><table cellpadding="5" cellspacing="0" border="0"><tr><td align="CENTER" valign="TOP"><textarea name="body" cols="45" rows="20" wrap="VIRTUAL"><?PHP echo $p_body; ?></textarea></td></tr></table></td>
  </tr>
  <tr>
!     <td <?PHP echo bgcolor($TableBodyColor1); ?> colspan=2 width="100%" nowrap align="left"><font color="<?PHP echo $TableBodyFontColor1; ?>"><input type="checkbox" name="email_reply" value="Y"><?PHP echo $lEmailMe; ?></font></td>
  </tr>
  <tr>
      <td width="100%" colspan="2" align="RIGHT" <?PHP echo bgcolor($TableBodyColor1); ?>><?PHP echo $quote_button; ?>&nbsp;<input type="Submit" name="post" value=" <?PHP echo $lFormPost;?> ">&nbsp;<br><img src="images/trans.gif" width=3 height=3 border=0></td>
diff -cr --exclude=*.txt --exclude=*.diff phorum306/phorum306/list.php3 phorum307/phorum307/list.php3
*** phorum306/phorum306/list.php3	Thu Oct 21 09:27:02 1999
--- phorum307/phorum307/list.php3	Thu Sep 16 14:25:24 1999
***************
*** 94,99 ****
--- 94,100 ----
      }
      else{
        $sSQL = "Select thread, count(*) as tcount, max(datestamp) as latest, max(id) as maxid from $TableName where thread > $cutoff_thread group by thread order by thread desc".$limit;
+       echo "<!--$sSQL-->\n";
      }
    }
    else{
***************
*** 112,117 ****
--- 113,119 ----
      }
      else{
        $sSQL = "Select thread, count(*) as tcount, max(datestamp) as latest, max(id) as maxid from $TableName  where thread < $thread and thread > $cutoff_thread group by thread order by thread desc".$limit;
+       echo "<!--$sSQL-->\n";
      }
    }
    $thread_list = new query($DB, $sSQL);
***************
*** 124,138 ****
        exit();
    }
  
!   $rec=$thread_list->getrow();
!   if($isset($rec['thread'])){
!     $max = $thread_list->field("thread", 0);
!     $min = $thread_list->field("thread", $rows-1);
!   }
!   else{
!     $max=0;
!     $min=0;
!   }
  
    if($$phcollapse==0){
      $sSQL = "Select id,parent,thread,subject,author,datestamp from $TableName where thread<=$max and thread>=$min order by thread desc, id asc";
--- 126,135 ----
        exit();
    }
  
!   echo "<!--\n";
!   $max = $thread_list->field("thread", 0);
!   $min = $thread_list->field("thread", $rows-1);
!   echo "-->\n";
  
    if($$phcollapse==0){
      $sSQL = "Select id,parent,thread,subject,author,datestamp from $TableName where thread<=$max and thread>=$min order by thread desc, id asc";
diff -cr --exclude=*.txt --exclude=*.diff phorum306/phorum306/multi-threads.inc phorum307/phorum307/multi-threads.inc
*** phorum306/phorum306/multi-threads.inc	Thu Sep 16 12:01:00 1999
--- phorum307/phorum307/multi-threads.inc	Thu Oct 21 09:35:04 1999
***************
*** 70,76 ****
      }
  
      $subject.="&nbsp;&nbsp;</font>";
!     if($haveread[0]<$topic["id"] && !IsSet($haveread[$topic["id"]]) && $UseCookies){
        $subject.="<font face=\"MS Sans Serif,Geneva\" size=\"-2\" color=\"#FF0000\">".$lNew."</font>";
      }
      $subject.="</TD>\n</TR>\n</TABLE>";
--- 70,82 ----
      }
  
      $subject.="&nbsp;&nbsp;</font>";
!     if(isset($haveread[0])){
!       $temp=$haveread[0];
!     }
!     else{
!       $temp=0;
!     }
!     if($temp<$topic["id"] && !IsSet($haveread[$topic["id"]]) && $UseCookies){
        $subject.="<font face=\"MS Sans Serif,Geneva\" size=\"-2\" color=\"#FF0000\">".$lNew."</font>";
      }
      $subject.="</TD>\n</TR>\n</TABLE>";
***************
*** 114,120 ****
          }
        }
  
!       if(is_array($messages[$seed]["replies"])){
          if(IsSet($messages[$parent]["images"])){
            $messages[$seed]["images"]=$messages[$parent]["images"];
            if($seed==$messages["$parent"]["max"]){
--- 120,127 ----
          }
        }
  
! 
!       if(isset($messages[$seed]["replies"])){
          if(IsSet($messages[$parent]["images"])){
            $messages[$seed]["images"]=$messages[$parent]["images"];
            if($seed==$messages["$parent"]["max"]){
***************
*** 122,128 ****
            }
            else{
              $messages[$seed]["images"].=$i_gif;
!           }  
          }
          $image.=$m_gif;
        }
--- 129,135 ----
            }
            else{
              $messages[$seed]["images"].=$i_gif;
!           } 
          }
          $image.=$m_gif;
        }
***************
*** 143,149 ****
        echo_data($image, $messages[$seed], $row_color_cnt);
      }//end of: if($seed!="0")
      
!     if(is_array($messages[$seed]["replies"])){
        $count=count($messages[$seed]["replies"]);
        for($x=1;$x<=$count;$x++){
          $key=key($messages[$seed]["replies"]);
--- 150,156 ----
        echo_data($image, $messages[$seed], $row_color_cnt);
      }//end of: if($seed!="0")
      
!     if(isset($messages[$seed]["replies"])){
        $count=count($messages[$seed]["replies"]);
        for($x=1;$x<=$count;$x++){
          $key=key($messages[$seed]["replies"]);
