SoFunction
Updated on 2025-04-13

A PHP forum program source code that imitates OSO (third)


</td> 
  </tr> 
  <tr>  
<td width="390" class="text">Total posts <font color="#ff0000">
    <? 
     print $li_replycount; 
    ?> 
</font> , read <font color="#ff0000">
    <? 
     print $li_readcount; 
    ?> 
</font> Times</td>
    <td colspan="3">&nbsp;</td> 
  </tr> 
</table> 
<? 
//Show all content of the post
$ls_query = 'select content,replyman,replytime,replyemail,replyhttp,replyface from fr_t_forumcontent '; 
$ls_query =  $ls_query. ' where id = '.$theme_id.' order by replytime'; 
$res = mysql_query($ls_query, $dbh);  
$li_tempr = 0; 
while ($row = mysql_fetch_array($res)) {  
  if ($li_tempr == 0) { 
  $li_tempr = 1;   
  print '<table width="100%" border="0" bgcolor="#CCCCCC">'; 
  print '  <tr bgcolor="#dedede" bordercolor="#CCCCFF"> '; 
  print ' <td class="text" height="19" valign="top" width="5%"> <div align="left">'; 
  print '  <img src="icon'.$row["replyface"].'.gif" width="18" height="18" ></div> </td>'; 
  print '    <td class="text" height="19" valign="top" width="20%"> '; 
print '      <div align="left"><font color="#3333FF">Author: '.$row["replyman"].'</font></div>';
  print '    </td>'; 
  print '    <td class="text" height="19" valign="top" width="25%">'; 
print  ' <font color="#3333FF">Published in: '.$row["replytime"].'</font></td>';
  print '    <td class="text" height="19" valign="top" width="25%">'; 
  print ' <font color="#3333FF">E_mail:'.$row["replyemail"].'</font></td>'; 
  print '    <td class="text" height="19" valign="top" width="25%">'; 
  print '<font color="#3333FF">'.$row["replyhttp"].' </font></td>'; 
  print '  </tr>'; 
  print '  <tr bgcolor="#dedede" bordercolor="#CCCCFF"> '; 
  print '    <td class="text" height="22" valign="top" colspan="5"> '; 
  print '      <p><font color="#3333FF">'.$row["content"].'</font></p>'; 
  print '    </td>'; 
  print '  </tr>'; 
  print '</table>'; 
  } 
  else { 
$li_tempr = 0;   
print '<table width="100%" border="0" bgcolor="#CCCCCC">'; 
print '  <tr bgcolor="#ededed"> '; 
print ' <td class="text" height="19" valign="top" width="5%"> <div align="left">'; 
print '  <img src="icon'.$row["replyface"].'.gif" width="18" height="18" ></div> </td>'; 
print '    <td class="text" height="19" valign="top" width="20%" bgcolor="#ededed"> '; 
print '      <div align="left"><font color="#000099">Author: '.$row["replyman"].'</font></div>';
print '    </td>'; 
print '    <td class="text" height="19" valign="top" width="25%">'; 
print ' <font color="#000099">Published in: '.$row["replytime"].' </font></td>';
print '    <td class="text" height="19" valign="top" width="25%">'; 
print '<font color="#000099">E_mail:'.$row["replyemail"].'</font></td>'; 
print '    <td class="text" height="19" valign="top" width="25%">'; 
print '<font color="#000099">'.$row["replyhttp"].' </font></td>'; 
print '  </tr>'; 
print '  <tr bgcolor="#ededed"> '; 
print '    <td class="text" height="22" valign="top" colspan="5"> '; 
print '      <p><font color="#000099">'.$row["content"].'</font></p>'; 
print '    </td>'; 
print '  </tr>'; 
print '</table>'; 


?> 
<? 
  include ("c:"); 
?> 
</HTML> 
----------