Witam, po zainstalowaniu skryptu "MobileBB" - forum mobilne, mam błąd, instalacja przebiegła poprawnie, bez żadnych komplikacji..

treść błędu:

  1. Parse error: syntax error, unexpected T_STRING in ..../vforum.php on line 13


kompletnie nie mam pojecia o co moze chodzić, proszę o pomoc...

plik vforum.php:

  1. <?php
  2. // ORDER BY topic_sticky DESC, topic_create_dt DESC LIMIT $startfrom,$topicsperpage
  3. if(!isset($_GET['id'])) $_GET["id"]='0';
  4. $id=substr($_GET["id"],0,5);
  5.  
  6. // Post new topic seciton
  7. $error = false;
  8. $submit_parm = '';
  9. if (isset($_POST['new_title'])) $new_title=$_POST['new_title']; else $new_title='';
  10. if (isset($_POST['new_message'])) $new_message=$_POST['new_message']; else $new_message='';
  11. if (isset($_POST['new_submit']) && $user_level>=5 && is_numeric($_POST['new_forumid']) && $_POST['seccodeverify']=='')
  12. {
  13. if (strlen($new_title)<4 || strlen($new_message)<4) { $error='Topic or message is too short.'; goto register;}
  14. if (strlen($new_title+$new_message)>$spam_maxpostlength) { $error='Topic or message is too short.'; goto register;}
  15. if (preg_match("/\<|\>/si",$new_title.$new_message) && $user_level<9) { $error='HTML is not allowed.'; goto register;}
  16. if (preg_match_all("/http/si",$new_title.$new_message)>3 && $user_level<9) { $error='HTML HTTP is not allowed.'; goto register;}
  17. if (preg_match('#\b[0-9A-Za-z_]{'.$spam_maxwordlength.',}\b#s',$new_message)!=0) { $error='Some words are too long ( maxwordlength ).'; goto register;}
  18. if (is_forumlocked($id) == TRUE && $user_level<9 ) { $error='Forum is locked.'; goto register;}
  19.  
  20. if ($spam_sec_num == true ) {
  21. if (chr(substr($_POST['spam_sec_num2'],0,2)) + date("h") != substr($_POST['spam_sec_num3'],0,2 + date("h")) ) { $error='Wrong calculation.'; goto register; } // if POST spam_sec condition
  22. } // if spam_sec num
  23. if ($error== false ) // if for PHP<5.3
  24. {
  25. mysql_query("INSERT INTO board_topics
  26. (topic_parent,topic_title,topic_create_dt,topic_lastpost_dt,topic_poster_id)
  27. values ('".$_POST['new_forumid']."','".$new_title."','".time()."','".time()."','".$user_id."')") or die(mysql_error());
  28. $post_parent_id=$_POST['new_forumid'];
  29. $post_id=mysql_insert_id();
  30. mysql_query("INSERT INTO board_comments
  31. (post_parent_id,post_author_id,post_author_ip,post_create_dt,post_text)
  32. values ('".mysql_insert_id()."','".$user_id."','".$user_ip."','".time()."','".$new_message."')
  33. ") or die(mysql_error());
  34. mysql_query("UPDATE board_forums SET `forum_lastpost_id`='".$post_id."',`forum_numtopics` = `forum_numtopics` + 1 where `forum_id`='".$post_parent_id."' limit 1") or die(mysql_error());
  35. $submit_parm = 'disabled';
  36. } // if error==false
  37. } //if isset new_submit
  38. register:
  39. // Post new topic end
  40.  
  41.  
  42. $line = 0;
  43. $page = 1;
  44. if ($id==0)
  45. {
  46. $result = mysql_query("SELECT * from board_forums WHERE forum_parent='$id' order by forum_name asc") or die(mysql_error());
  47. while($row = mysql_fetch_assoc($result))
  48. {
  49. $row_color = !$row_color;
  50. echo "<div class='".$row_colors[$row_color]."'><h2>";
  51. // print_r ($row);
  52. if ($user_level==9) echo "<a href='?action=admin&action2=edit_forum&id=".$row['forum_id']."'>EDIT</a> ";
  53. echo "<a href='?action=vforum&id=".$row['forum_id']."'>".$row['forum_name']."</a></h2>";
  54. echo "<i>".$row['forum_desc']." &nbsp</i> <div>".$lang['last'].": <a href='?action=vtopic&id=".$row['forum_lastpost_id']."'>".substr(get_topic_title($row['forum_lastpost_id']),0,15)."</a>, Topics: ".$row['forum_numtopics']." </div>";
  55. // echo '[forum_numtopics] => 0 [forum_numreplies] => 0 [forum_lastpost_id]<br/>';
  56. echo "</div>";
  57.  
  58. } // while row
  59. }
  60. else
  61. {
  62. if (isset($_GET['page'])) { if(is_numeric($_GET['page'])) $page=substr($_GET['page'],0,5);}
  63. $query = "SELECT * from board_topics WHERE topic_parent='$id' order by topic_sticky desc,topic_lastpost_dt desc limit ".($page -1) * $topicsperpage.",".$topicsperpage;
  64. $result = mysql_query($query) or die(mysql_error());
  65. if (mysql_num_rows($result) == 0) { echo '<div class=even>'.$lang['empty'].'</div>';}
  66. while($row = mysql_fetch_assoc($result))
  67. {
  68. $row_color = !$row_color;
  69. $line++;
  70. echo "<div class='".$row_colors[$row_color]."'><h2>";
  71. if ($user_level==9) echo "<a href='?action=admin&action2=edit_topic&id=".$row['topic_id']."'>EDIT</a> ";
  72. if ($row['topic_locked'] == true) echo '[L] ';
  73. if ($row['topic_sticky'] == true) echo '[S] ';
  74. if ($modrewrite == true )
  75. {
  76. echo "<a href='/topics/".$row['topic_id']."/".str_replace(" ",'_',$row['topic_title'])."'>".$row['topic_title']."</a>";
  77. } else
  78. {
  79. echo "<a href='?action=vtopic&id=".$row['topic_id']."'>".$row['topic_title']."</a>";
  80. } // else modrewrite false
  81. echo "</h2>";
  82. echo "".$lang['created'].': '.date("Y-m-d H:i",$row['topic_create_dt'])." by ".get_username($row['topic_poster_id']).' ,'.$lang['viewed'].': '.$row['topic_numviews']."";
  83. if ($row['topic_numreplies']>0)
  84. { echo "<div>Last: ".date("Y-m-d",$row['topic_lastpost_dt'])." ".$lang['replies'].": ".$row['topic_numreplies']."</div>"; }
  85. echo "";
  86. echo "</div>";
  87.  
  88. } // while row
  89. } // if id==0
  90.  
  91. // PAGINATION list
  92. echo '<br><div class=\'pagination\'>'.$lang['page'].':';
  93. if ($page>1) echo '<a href=\'?action=vforum&id='.$id.'&page='.($page-1).'\'>'.($page-1).'</a> ';
  94. echo '< <a href=\'?action=vforum&id='.$id.'&page='.$page.'\'> '.$page.'</a> > ';
  95. if ($line>=$topicsperpage) echo '<a href=\'?action=vforum&id='.$id.'&page='.($page+1).'\'>'.($page+1).'</a> ';
  96. echo '</div><br>';
  97.  
  98.  
  99. if ($id!=0)
  100. {
  101. echo "<div class=newreply>";
  102. if ($user_level<5)
  103. {
  104. echo "<div class='error'>Your account doesn't have privileges to post new topic.</div><br>";
  105. } else
  106. {
  107. echo "<div class='group'>".$lang['new_topic']."</div></br>";
  108. if ($error) echo "<div class='error'>$error</div><br>";
  109. echo "<form method=post>
  110. Title:<br>
  111. <input type=text name='new_title' value='".$new_title."'><br>
  112. Message:<br>
  113. <textarea name=new_message rows=6 ".$submit_parm.">".$new_message."</textarea><br><br>";
  114. if ($spam_sec_num == true )
  115. {
  116. $spam_sec_num1= date ("h");
  117. $spam_sec_num2= rand (1,9);
  118. echo $spam_sec_num2." + ".$spam_sec_num1." = ? <input type=tel size=4 name='spam_sec_num3' ".$submit_parm."><input type=hidden name='spam_sec_num2' value='".ord($spam_sec_num2)."'><br><br>";
  119. } // if spam_sec_num
  120. echo "<input type=submit name='new_submit' value='submit' ".$submit_parm.">
  121. <input type=hidden name='new_forumid' value='".$id."'>";
  122. echo "<input id=\"seccodeverify\" type=\"text\" maxlength=\"4\" size=\"8\" name=\"seccodeverify\">"; // anti bot field generator spam , keep this value clear and hidden in css
  123. echo "</form>";
  124.  
  125.  
  126. } // if user level<5
  127. echo "</div>";
  128. } // id!=0
  129.  
  130. ?>


kompletnie nie wiem o co może chodzić... proszę o pomoc..

Nieaktualne, była za stara wersja php.