Просмотр файла eforum25/show.php

Размер файла: 3.04Kb
  1. <?php
  2. include "config.php";
  3. include "incl/head.inc";
  4. if(!isset($topic)){redirect("main.php?f=$f");}
  5. else{$file="$data/$topic";
  6. file_allowed($topic);}
  7.  
  8. $fs=open_file($file);
  9. $fs=explode("\n",$fs);
  10. if(count($fs)>=$posts_max){$add_post='';}
  11. else{$add_post=$lang[19];}
  12.  
  13. ?><title><?php print $lang[29];?>...</title>
  14. </head><body><?php include "incl/cust-top.inc";?>
  15. <table width="100%" border="0" cellpadding="0" cellspacing="0"><tr><td class="q">
  16. <table width="100%" border="0" cellspacing="1" cellpadding="<?php print $cellpadding;?>"><tr class="c"><td colspan="3">
  17. <table width="100%" cellpadding="2" cellspacing="0"><tr><td nowrap="nowrap"><span class="c"><a href="main.php" id="lnk" title="<?php print $lang[0];?>" style="color:#ffffff;text-decoration:none" onmouseover="start_impress();return true" onmouseout="stop_impress();return true" onclick="refresh(<?php print $f;?>);return false"><?php print $forum_name[$f];?></a></span></td><td align="right" nowrap="nowrap"><b><a style="color:#ffffff" href="add.php?f=<?php print $f;?>&amp;topic=<?php print $topic; ?>"><?php print $add_post;?></a></b></td></tr></table></td></tr>
  18. <tr class="z"><td class="f" width="20%" nowrap="nowrap">&nbsp;<?php print $lang[28];?>&nbsp;</td><td class="f" width="70%" nowrap="nowrap">&nbsp;<?php print $lang[17];?>&nbsp;</td><td class="f" width="10%" nowrap="nowrap">&nbsp;<?php print $lang[15];?>&nbsp;</td></tr>
  19. <?php
  20.  
  21. for($i=0;$i<count($fs);$i++){
  22. if(isset($fs[$i])&&strlen($fs[$i])>9){
  23. $row=explode(":|:",$fs[$i]);
  24.  
  25. $pic_number=explode(".gif",$row[2]);
  26. $pic_number=substr($pic_number[0], -1);
  27. if(isset($memname)&&strstr($row[2],'onclick')&&strtolower(strip_tags($row[2]))==strtolower($memname)&&$members_edit==1){
  28. $edit="<div align=\"right\"><a href=\"edit.php?f=$f&amp;topic=$topic&amp;line=$i\">$lang[22]</a></div>";
  29. }else{$edit='';}
  30.  
  31. if(!strstr($row[0],' ')){$row[0]=time_offset($row[0]);}
  32. if(!isset($row[4])||$row[4]==''||$row[4]=='http://'){$img='';}else{$img="<img src=\"$row[4]\" align=\"right\" border=\"1\" width=\"50\" height=\"50\" onclick=\"show_image(this,'$row[4]')\" vspace=\"4\" hspace=\"4\" onmouseover=\"this.style.cursor='hand'\" onmouseout=\"this.style.cursor='default'\" alt=\"$lang[42]\" title=\"$lang[42]\" />";}
  33. if(strstr($row[3],'@')){$row[3]=eregi_replace("([A-z0-9._-]+)@([A-z0-9._-]+)","<script type=\"text/javascript\">show_mail('\\1','\\2')</script>",$row[3]);}
  34.  
  35. print "\n<tr class=\"$row_bg\"><td><b>$row[2]</b><br clear=\"all\" /><img src=\"pics/b$pic_number.gif\" $size_img[3] alt=\"\" hspace=\"1\" align=\"left\" /><b>$row[1]</b></td>";
  36. print "\n<td class=\"s\">$img $row[3] $edit</td><td class=\"s\" nowrap=\"nowrap\">$row[0]</td></tr>";
  37. switch_row_bg();}}
  38. print "\n<tr class=\"$row_bg\"><td class=\"r\" colspan=\"2\">&nbsp;<a href=\"add.php?f=$f&amp;topic=$topic\">$add_post</a></td><td align=\"center\" class=\"r\"><a href=\"#\" onclick=\"self.scrollTo(0,0);return false\">$lang[30]</a></td></tr>";
  39. ?>
  40. </table></td></tr></table>
  41. <?php $color_changing=0;include "incl/clrs.inc";?>
  42. <br clear="all" /><?php include "incl/cust-bot.inc";?>
  43. </body></html>