Det er sandsynligvis fordi der er fejl i scriptet - jeg har ikke haft mulighed for at teste det selv... Din server burde dog give en fejlmeddelelse a la PARSE ERROR... Har den ikke givet fejlmeddelelser tidligere?
Der manglede et }'er... Prøv at sætte den ind nu:
<?php
$side = ".";
require "$side/funcs.php";
$query = mysql_query("SELECT * FROM forum_thread WHERE id = '$_GET[id]' LIMIT 1");
$t = mysql_fetch_array($query);
$side_titel = "Tråd: $t[overskrift]";
$query = mysql_query("SELECT * FROM forum_board WHERE id = '$_GET[board]' LIMIT 1");
$b = mysql_fetch_array($query);
$query = mysql_query("SELECT * FROM forum_emne WHERE id = '$_GET[emneId]' LIMIT 1");
$r = mysql_fetch_array($query);
$hvor = "<a href=\"./?emneId=$_GET[emneId]\">Emne: $r[emne]</a> > <a href=\"./board.php?emneId=$_GET[emneId]&board=$_GET[board]\">Board: $b[board]</a> > <b>" . $side_titel . "</b>";
include "$side/includes/header.php";
?>
<!-- indhold start -->
<script type="text/javascript" language="JavaScript">
<!--
function FormValidator(theForm)
{
if (document.post.bruger.value == '') {
alert('Du skal skrive dit navn\n\nOpret en bruger og slip for at udfylde Navn-feltet!');
document.post.bruger.focus();
return (false);
}
if (document.post.bruger.value == 'Dit navn') {
alert('Du skal skrive dit navn\n\nOpret en bruger og slip for at udfylde Navn-feltet!');
document.post.bruger.focus();
return (false);
}
if (document.post.tekst.value == '') {
alert('Du skal skrive noget i Tekst-feltet');
document.post.tekst.focus();
return (false);
}
if (document.post.tekst.value == 'Dit svar') {
alert('Du skal skrive noget i Tekst-feltet');
document.post.tekst.focus();
return (false);
}
}
function makeBold() {
sT = document.selection.createRange();
sTxt = sT.text;
if(!sTxt.length > 0) { return( false); }
sT.text = "[B]" + sTxt + "[/B]";
}
function makeItalic() {
sT = document.selection.createRange();
sTxt = sT.text;
if(!sTxt.length > 0) { return( false); }
sT.text = "[I]" + sTxt + "[/I]";
}
function makeUnderstreget() {
sT = document.selection.createRange();
sTxt = sT.text;
if(!sTxt.length > 0) { return( false); }
sT.text = "[U]" + sTxt + "[/U]";
}
function makeLink() {
sT = document.selection.createRange();
sTxt = sT.text;
if(!sTxt.length > 0) { return( false); }
sT.text = "[url]" + sTxt + "[/url]";
}
function makeCitat() {
sT = document.selection.createRange();
sTxt = sT.text;
if(!sTxt.length > 0) { return( false); }
sT.text = "
"" + sTxt + ""
";
}
function makeKode() {
sT = document.selection.createRange();
sTxt = sT.text;
if(!sTxt.length > 0) { return( false); }
sT.text = "[KODE]" + sTxt + "[/KODE]";
}
function makeBillede() {
sT = document.selection.createRange();
sTxt = sT.text;
if(!sTxt.length > 0) { return( false); }
sT.text = "[BILLEDE]" + sTxt + "[/BILLEDE]";
}
function emoticon(text) {
text = '' + text + '';
if (document.post.tekst.createTextRange && document.post.tekst.caretPos) {
var caretPos = document.post.tekst.caretPos;
caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == '' ? text + '' : text;
document.post.tekst.focus();
} else {
document.post.tekst.value += text;
document.post.tekst.focus();
}
}
function NewWin () {
HELP=window.open('ehtml_popup.htm','help','width=500,height=450,toolbar=no,scrollbars=yes')
}
function land(ref, target)
{
lowtarget=target.toLowerCase();
if (lowtarget=="_self") {window.location=loc;}
else {if (lowtarget=="_top") {top.location=loc;}
else {if (lowtarget=="_blank") {window.open(loc);}
else {if (lowtarget=="_parent") {parent.location=loc;}
else {parent.frames[target].location=loc;};
}}}
}
function jump(menu)
{
ref=menu.choice.options[menu.choice.selectedIndex].value;
splitc=ref.lastIndexOf("*");
target="";
if (splitc!=-1)
{loc=ref.substring(0,splitc);
target=ref.substring(splitc+1,1000);}
else {loc=ref; target="_self";};
if (ref != "") {land(loc,target);}
}
function FormValidatorDummy(theForm)
{
if (document.dummy.choice.value == 'dum') {
alert('Du kan ikke vælge det "Quick-menu" punkt!');
return (false);
}
}
//-->
</script>
<table width="100%" cellspacing="1" cellpadding="2" class="tabelBox">
<?php
$sets = mysql_query("SELECT pr_side_t FROM forum_settings WHERE id = '1' LIMIT 1");
$rS = mysql_fetch_array($sets);
$pr_side = $rS["pr_side_t"];
$s = $_GET['s'];
if (!isset($s)) {
$s = "0";
}
if((!$s) || ($s == 0)){
$pr_side = $pr_side - 1;
if(($_COOKIE['loginId']) && ($_USER['rang'] == 2) || ($_USER['rang'] == 3)){
$queryThread = mysql_query("SELECT * FROM forum_thread WHERE id = '$_GET[id]' LIMIT 1");
} else {
$queryThread = mysql_query("SELECT * FROM forum_thread WHERE id = '$_GET[id]' AND public = '1' LIMIT 1");
}
$row = mysql_fetch_array($queryThread);
$id = $row["id"];
$emneId = $row["emneId"];
$board = $row["board"];
$text = $row["text"];
$overskrift = $row["overskrift"];
$tbrugerId = $row["brugerId"];
$tbruger = $row["bruger"];
$emneId = $row["emneId"];
$public = $row["public"];
$last_edit_stamp = $row["last_edit_stamp"];
$last_edit_date = date("$_SETS[dato_form]", $row[last_edit_stamp]);
$lock = $row["lock"];
$date = date("$_SETS[dato_form]", $row[date_stamp]);
$query = mysql_query("SELECT * FROM forum_users WHERE id = '$tbrugerId' LIMIT 1");
$user = mysql_fetch_array($query);
?>
<script type="text/javascript" language="JavaScript">
<!--
function Pm<?=$id;?>() {
window.open("./users/pm.php?til=<?=$tbrugerId;?>","Pm","width=250,height=180,resizable=no,scrollbars=no");
}
function sendThread() {
window.open("sendThread.php?emneId=<?=$_GET[emneId];?>&board=<?=$_GET[board];?>&id=<?=$_GET[id];?>","sendThread","width=380,height=240,resizable=no,scrollbars=no");
}
//-->
</script>
<?php
include "./replace.php";
echo "
<tr class=\"tr\">
<td width=\"125\">
Forfatter:
</td>
<td>
Overskrift: <b>$overskrift</b>
</td>
<form action=\"../dummy\" method=\"post\" name=\"dummy\" onSubmit=\"return FormValidatorDummy(this);\">
<td align=\"right\">
Quick menu: <select name=\"choice\" size=\"1\" onchange=\"jump(this.form)\" class=\"inputMenu\">
<option value=\"dum\">Vælg et emne/board...</option>";
if(($_COOKIE['loginId']) && ($_USER['rang'] == 2) || ($_USER['rang'] == 3)){
$emneQuery = mysql_query("SELECT * FROM forum_emne ORDER BY sort");
} else {
$emneQuery = mysql_query("SELECT * FROM forum_emne WHERE public = '1' ORDER BY sort");
}
while($r = mysql_fetch_array($emneQuery)) {
echo "
<option value=\"./?emneId=$r[id]\" class=\"emneSelectMenu\">$r[emne]</option>";
if(($_COOKIE['loginId']) && ($_USER['rang'] == 2) || ($_USER['rang'] == 3)){
$boardQuery = mysql_query("SELECT * FROM forum_board WHERE emneId = '$r[id]' ORDER BY sort");
} else {
$boardQuery = mysql_query("SELECT * FROM forum_board WHERE emneId = '$r[id]' AND public = '1' ORDER BY sort");
}
while($r2 = mysql_fetch_array($boardQuery)) {
echo "
<option value=\"board.php?emneId=$r[id]&board=$r2[id]\" class=\"inputMenu\">$r2[board]</option>";
}
}
echo "
</select>
</td></form></tr>
<form action=\"edit_traad.php\" method=\"post\">
<tr class=\"tdUlige\" valign=\"top\">
<td width=\"110\">
<div class=\"postForfatter\">";
if ($tbrugerId == '-gæst'){
echo "
<b>$tbruger</b><br />
<font size=\"1\">Gæst";
} else {
echo "
<b><a href=\"./users/show.php?brugerId=$tbrugerId\">$tbruger</a></b><br />
<font size=\"1\">";
if($user['rang'] == 1){
echo "Bruger";
} elseif($user['rang'] == 2){
echo "CoAdmin";
} elseif($user['rang'] == 3){
echo "Admin";
}
if($_SETS['avatar'] != 0 && $user['avatar'] != 0){
if($_SETS['avatar'] == 1 || $_SETS['avatar'] == 2 && $user['avatar'] == 1 && $user['avatar_web'] != NULL){
echo "<br /><img src=\"$user[avatar_web]\" border=\"0\" />";
} elseif($_SETS['avatar'] == 2 || $_SETS['avatar'] == 3 && $user['avatar'] == 1 && $user['avatar_upload'] != NULL){
echo "<br /><img src=\"./avatar/$user[avatar_upload]\" border=\"0\" />";
}
}
if($_SETS['posts'] == 1){
$query = mysql_query("SELECT COUNT(*) as antal FROM forum_reply WHERE brugerId = '$tbrugerId'");
$fr = mysql_fetch_array($query);
$query = mysql_query("SELECT COUNT(*) as antal FROM forum_thread WHERE brugerId = '$tbrugerId'");
$ft = mysql_fetch_array($query);
$indlaeg = $fr[antal] + $ft[antal];
echo "<br /><br />
Indlæg: $indlaeg";
} else {
echo "<br />";
}
if(($_COOKIE['loginId']) && ($_COOKIE['loginId'] != $tbrugerId)){
echo "<br /><input type=\"button\" class=\"pm\" value=\"PM\" name=\"sendPM\" onclick=\"java script:Pm$id();\" target=\"Pm\" />";
}
}
echo "</font></div>
<input type=\"hidden\" value=\"$board\" name=\"board\" />
<input type=\"hidden\" value=\"$id\" name=\"id\" />
<input type=\"hidden\" value=\"$emneId\" name=\"emneId\" />
</td>
<td colspan=\"2\">
<div class=\"postTop\">
<b>Indlæg #1</b> skrevet $date ";
if($lock != 1){
if($_USER['rang'] == 2){
echo "<input type=\"submit\" class=\"rbutton\" value=\"Rediger/flyt/lås tråd\" name=\"send\" />";
} elseif($_USER['rang'] == 3){
echo "<input type=\"submit\" class=\"rbutton\" value=\"Rediger/flyt/slet/lås tråd\" name=\"send\" />";
} elseif(($tbrugerId == $_COOKIE['loginId']) && ($_USER['rang'] == 1)){
echo "<input type=\"submit\" class=\"rbutton\" value=\"Rediger tråd\" name=\"send\" />";
}
}
if(($lock == 1) && ($_USER['rang'] == 2 || $_USER['rang'] == 3)){
echo "<input type=\"submit\" class=\"rbutton\" value=\"Lås tråd op\" name=\"send\" />";
}
echo "</div>
<div class=\"postText\">
$text";
if ($last_edit_stamp != NULL){
echo "
<hr width=\"100%\" align=\"left\" size=\"0\" />
<i><font size=\"1\">Sidst redigeret: $last_edit_date</font></i>";
}
echo "
</div></td></tr></form>";
}
if(($_COOKIE['login']) && ($_USER['rang'] == 2) || ($_USER['rang'] == 3)){
$queryReply = mysql_query("SELECT * FROM forum_reply WHERE reply_to = '$_GET[id]' ORDER BY id LIMIT $s,$pr_side");
} else {
$queryReply = mysql_query("SELECT * FROM forum_reply WHERE reply_to = '$_GET[id]' AND public = '1' ORDER BY id LIMIT $s,$pr_side");
}
if((!$s) || ($s == 0)){
$i = 1;
} else {
$i = 0;
}
while ($row = mysql_fetch_array($queryReply)) {
$replyId = $row["id"];
$text = $row["text"];
$overskrift = $row["overskrift"];
$brugerId = $row["brugerId"];
$bruger = $row["bruger"];
$last_edit_stamp = $row["last_edit_stamp"];
$last_edit_date = date("$_SETS[dato_form]", $row[last_edit_stamp]);
$date = date("$_SETS[dato_form]", $row[date_stamp]);
$query = mysql_query("SELECT * FROM forum_users WHERE id = '$brugerId' LIMIT 1");
$user = mysql_fetch_array($query);
include "./replace.php";
$i++;
?>
<script type="text/javascript" language="JavaScript">
<!--
function Pm<?=$replyId;?>() {
window.open("./users/pm.php?til=<?=$tbrugerId;?>","Pm","width=250,height=180,resizable=no,scrollbars=no");
}
//-->
</script>
<?php
if ($i%2 == 1) {
$class = "tdUlige";
} else {
$class = "tdLige";
}
$svar = $i + $s;
echo "
<form action=\"./edit_svar.php\" method=\"post\">
<tr valign=\"top\" class=\"$class\">
<td width=\"110\">
<div class=\"postForfatter\">";
if ($brugerId == '-gæst'){
echo "
<b>$bruger</b><br />
<font size=\"1\">Gæst";
} else {
echo "
<b><a href=\"./users/show.php?brugerId=$brugerId\">$bruger</a></b><br />
<font size=\"1\">";
if($user['rang'] == 1){
echo "Bruger";
} elseif($user['rang'] == 2){
echo "CoAdmin";
} elseif($user['rang'] == 3){
echo "Admin";
}
if($_SETS['avatar'] != 0 && $user['avatar'] != 0){
if($_SETS['avatar'] == 1 || $_SETS['avatar'] == 2 && $user['avatar'] == 1 && $user['avatar_web'] != NULL){
echo "<br /><img src=\"$user[avatar_web]\" border=\"0\" />";
} elseif($_SETS['avatar'] == 2 || $_SETS['avatar'] == 3 && $user['avatar'] == 1 && $user['avatar_upload'] != NULL){
echo "<br /><img src=\"./avatar/$user[avatar_upload]\" border=\"0\" />";
}
}
if($_SETS['posts'] == 1){
$query = mysql_query("SELECT COUNT(*) as antal FROM forum_reply WHERE brugerId = '$brugerId'");
$fr = mysql_fetch_array($query);
$query = mysql_query("SELECT COUNT(*) as antal FROM forum_thread WHERE brugerId = '$brugerId'");
$ft = mysql_fetch_array($query);
$indlaeg = $fr[antal] + $ft[antal];
echo "<br /><br />
Indlæg: $indlaeg";
} else {
echo "<br />";
}
if(($_COOKIE['loginId']) && ($brugerId != '-gæst') && ($_COOKIE['loginId'] != $brugerId)){
echo "<br /><input type=\"button\" class=\"pm\" value=\"PM\" name=\"sendPM\" onclick=\"java script:Pm$replyId();\" target=\"Pm\" />";
}
}
echo "</font></div>
<input type=\"hidden\" value=\"$replyId\" name=\"id\" />
</td>
<td colspan=\"2\">
<div class=\"postTop\">
<b>Indlæg #$svar</b> skrevet $date ";
if($lock != 1){
if($brugerId == $_COOKIE['loginId']){
echo "<input type=\"submit\" class=\"rbutton\" value=\"Rediger/slet indlæg\" name=\"send\" />";
} elseif($_USER['rang'] == 2){
echo "<input type=\"submit\" class=\"rbutton\" value=\"Rediger indlæg\" name=\"send\" />";
} elseif($_USER['rang'] == 3){
echo "<input type=\"submit\" class=\"rbutton\" value=\"Rediger/slet indlæg\" name=\"send\" />";
}
}
echo "</div>
<div class=\"postText\">
$text";
if ($last_edit_stamp != NULL){
echo "
<hr width=\"100%\" align=\"left\" size=\"0\" />
<i><font size=\"1\">Sidst redigeret: $last_edit_date</font></i>";
}
echo "
</div></td></tr></form>";
}
?>
<tr class="tr">
<td>
</td>
<td align="right" colspan="2">
<input type="button" class="pm" value="Send tråd til ven" name="sendThread" onclick="java script:sendThread();" target="sendThread" />
<?php
if((!$_GET['s']) || ($_GET['s'] == 0)){
$pr_side = $pr_side + 1;
}
if(($_COOKIE['loginId']) && ($_USER['rang'] == 2) || ($_USER['rang'] == 3)){
$g_total = mysql_query("SELECT COUNT(id) AS total FROM forum_reply WHERE reply_to = '$_GET[id]'");
} else {
$g_total = mysql_query("SELECT COUNT(id) AS total FROM forum_reply WHERE reply_to = '$_GET[id]' AND public = '1'");
}
$total = mysql_result($g_total,0);
if ($s >= $pr_side) {
$previous_s = $s-$pr_side;
echo "
<a href=\"?s=$previous_s&emneId=$_GET[emneId]&board=$_GET[board]&id=$_GET[id]\"><<</a> ";
} else {
echo "<font class=\"alt\"><<</font> ";
}
$page = 1;
if($total == 0){
echo "<b>$page</b> ";
}
for($start=0; $total > $start; $start=$start+$pr_side){
if ($start != $s) {
echo "<a href=\"?s=$start&emneId=$_GET[emneId]&board=$_GET[board]&id=$_GET[id]\">$page</a> ";
} else {
echo "<b>$page</b> ";
}
$page++;
}
if ($total > $s+$pr_side) {
$next_s = $s+$pr_side;
echo "<a href=\"?s=$next_s&emneId=$_GET[emneId]&board=$_GET[board]&id=$_GET[id]\">>></a>";
} else {
echo "<font class=\"alt\">>></font>";
}
?>
</td></tr></table>
<br />
<?php if($lock != 1){
if($total <= $s+$pr_side){
if(isset($_COOKIE["login"])){ ?>
<table width="420" cellspacing="1" cellpadding="2" class="tabelBox">
<form method="post" action="./func.php?function=reply" name="post" onSubmit="return FormValidator(this);">
<tr class="tr">
<td align="center">
<b>Besvar tråd:</b>
</td></tr>
<tr class="trBackground">
<td>
<br /><div align="center">
<input type="button" value="Link" class="button" onClick="makeLink()" />
<input type="button" value="Fed" class="button" onClick="makeBold()" />
<input type="button" value="Kursiv" class="button" onClick="makeItalic()" />
<input type="button" value="Understreget" class="button" onClick="makeUnderstreget()" />
<br><br><input type="button" value="Citat" class="button" onClick="makeCitat()" />
<input type="button" value="Kode" class="button" onClick="makeKode()" />
<input type="button" value="Billede" class="button" onClick="makeBillede()" />
<br />
<a href="java script:NewWin()">Hjælp til knapperne!</a>
<br />
<img src="./img/smiley.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon(':)');" />
<img src="./img/frown.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon(':(');" />
<img src="./img/wink.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon(';)');" />
<img src="./img/biggrin.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon(':D');" />
<img src="./img/cool.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('8)');" />
<img src="./img/tongue.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon(':p');" />
<img src="./img/rolleyes.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('@-)');" />
<img src="./img/terrefied.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon(':0');" />
<img src="./img/sleep.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('|-I');" />
<img src="./img/eek.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('8-0');" />
<img src="./img/angry.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon(':||');" />
<img src="./img/sick.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('/sick');" />
<img src="./img/thumbup.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('/great');" />
<img src="./img/thumbdown.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('/bad');" />
<img src="./img/star.gif" border="0" onmouseover="this.style.cursor='hand';" onclick="emoticon('/star');" />
<br /></div>
<input type="hidden" name="reply_to" value="<?=$id;?>" />
<input type="hidden" name="board" value="<?=$board;?>" />
<input type="hidden" name="emneId" value="<?=$emneId;?>" />
<input type="hidden" name="s" value="<?=$s;?>" />
<?php
echo "
<input class=\"input\" type=\"text\" name=\"bruger\" size=\"30\" value=\"$_COOKIE[login]\" readonly=\"readonly\" />
<input type=\"hidden\" value=\"$_COOKIE[loginId]\" name=\"brugerId\" />";
$signQuery = mysql_query("SELECT * FROM forum_users WHERE id = '$_COOKIE[loginId]'");
$signR = mysql_fetch_array($signQuery);
echo "
<input type=\"hidden\" value=\"$signR[signatur]\" name=\"signatur\" /><br />";
if($signR['optSignatur'] == 1){
echo "
<input type=\"checkbox\" name=\"optSignatur\" checked=\"checked\" id=\"sign\" />";
} else {
echo "
<input type=\"checkbox\" name=\"optSignatur\" id=\"sign\" />";
}
echo "
<label for=\"sign\">Sæt min signatur på dette indlæg</label>";
?>
<br />
<textarea cols="50" rows="10" name="tekst" class="input" onFocus="if(this.value=='Dit svar')this.value='';" onBlur="if(this.value=='')this.value='Dit svar';">Dit svar</textarea>
<br />
<div align="center"><input type="submit" name="besvar" value="Besvar" class="button" /></div>
</td></tr></table></form>
<?php } else {
<table width="420" cellspacing="1" cellpadding="2" class="tabelBox">
<tr class="tr">
<td align="center">
<br /><br /><a href="./users/opret.php"><b>Opret en bruger nu</b></a>, og nyd godt af fordelene:
<br /><br />
<i><li>Mulighed for redigéring og sletning af svar.</li><br />
<li>Automatisk udfyldning af navn</li><br />
<li>Og meget mere, som er ved at blive lavet!</li></i>
</td>
</tr>
</table>
<?php }
else
{
echo "<b>Gå til sidste side for at besvare!</b><br />";
}}
else
{ ?>
<table cellspacing="1" cellpadding="2" class="tabelBox" width="420">
<tr>
<td align="center">
<br /><font color="#ff0000"><b>Denne tråd er låst, derfor kan der ikke oprettes nye indlæg, redigeres eller slettes eksisterende indlæg!</b></font><br /><br />
</td></tr></table>
<?php }} ?>
<!-- indhold slut -->
<?php include "$side/includes/footer.php"; ?>