View Single Post
  #12  
Old 05-26-2009, 11:45 AM
Bloodrun's Avatar
Bloodrun Bloodrun is offline
I am, who I am.
 
Join Date: Apr 2009
Posts: 532
Gender: Male
Credits: 29,651
Bloodrun
Send a message via Yahoo to Bloodrun
Default RE: Parse error: syntax error, unexpected T_ELSE in /home/.nyles/

Quote:
Originally Posted by Saphira
I changed the following:

PHP Code:
$article_title "<center>Message From <a href='profile.php?user=".$fromuser."' target='_blank'>".$fromuser."</a>:</center>
$article_content = "<center><b><u>Message Title:</u></b><br".$messagetitle."</center><br>
<
center><b><u>Message Text:</u></b><br".$messagetext."</center><br><br><b><a href='messages.php'><img src='templates/icons/next.gif' border=0> Return to Inbox</a><br
<
a href='messages.php?act=send&user=".$fromuser."'><img src='templates/icons/comment.gif' border=0Reply to this Message</a
to this:
PHP Code:
$article_title "<center>Message From <a href='profile.php?user=".$fromuser."' target='_blank'>".$fromuser."</a>:</center>
$article_content = "<center><b><u>Message Title:</u></b><br".$messagetitle."</center><br>
<
center><b><u>Message Text:</u></b><br".$messagetext."</center><br><br><b><a href='messages.php'><img src='templates/icons/next.gif' border=0> Return to Inbox</a><br
<
a href='messages.php?act=send&user=".$fromuser."'><img src='templates/icons/comment.gif' border=0Reply to this Message</a
<
br><a href='messages.php?act=report&user=".$fromuser."'><img src='templates/icons/next.gif' border=0Report this member</a><br></b>"; 
and also,

PHP Code:
else if($act == "send" or $act == "newpm"){

// Send a new message to someone else...

$article_title $lang_sendnew_title;
$article_content $lang_sendnew."<br><form name='form1' method='post' action='pmpost.php'>
  <p>Message Recipient: 
    <input name='pmto' type='text' id='pmto' maxlength='50' value='"
.$user."'>
</p>
  <p>Message Title: 
    <input name='mtitle' type='text' id='mtitle' maxlength='25'>
</p>
  <p>Message Text:  </p>
  <p>
    <textarea name='mtext' cols='45' id='mtext'></textarea>
</p>
  <p>
    <input type='submit' name='Submit' value='Send Private Message'>
</p>
</form>"



to this:

PHP Code:
else if($act == "send" or $act == "newpm"){

// Send a new message to someone else...

$article_title $lang_sendnew_title;
$article_content $lang_sendnew."<br><form name='form1' method='post' action='pmpost.php'>
  <p>Message Recipient: 
    <input name='pmto' type='text' id='pmto' maxlength='50' value='"
.$user."'>
</p>
  <p>Message Title: 
    <input name='mtitle' type='text' id='mtitle' maxlength='25'>
</p>
  <p>Message Text:  </p>
  <p>
    <textarea name='mtext' cols='45' id='mtext'></textarea>
</p>
  <p>
    <input type='submit' name='Submit' value='Send Private Message'>
</p>
</form>"


}
$article_title "Reporting a Member";
$article_content "You may report a member here, by providing a reason. Please only report a member if he/she is harassing you, or constantly spamming your inbox. This isn't a toy, and shouldn't be treated as such.<br><form name='form1' method='post' action='reportpost.php'>
  <p>
    <input name='member' type='hidden' id='member' maxlength='50' value='"
.$user."'>
</p>
  <p>
    <input name='fromuser' type='hidden' id='fromuser' maxlength='50' value='"
.$loggedinname."'>
</p>
  <p>Reason:  </p>
  <p>
    <textarea name='reason' cols='45' id='reason'></textarea>
</p>
  <p>
    <input type='submit' name='Submit' value='Send Report'>
</p>
</form>"



I also added an extra } to the bottom of the script, because I got an unexpected $end error, and this is the only way I know to fix that error.

Edit: I just noticed your reply before this one, and everything works fine now. Thanks for your help again Bloodrun!
Yeah your second edit is what messed everything up.

I had to get rid of the two brackets at the very bottom, and I had to add the 'else if($act = "report"){' statement for the report feature, because it will not work without it.
Reply With Quote