Jump to content

[SOLVED] unexpected ;


maxudaskin

Recommended Posts

Parse error: syntax error, unexpected ';' in /home/.grable/vzoom/virtualzoom.net/editpireps.php on line 333

 

I get that error, but line 333 is:

 

?>

 

<?php
if(!$logged_in){
   echo "<h1>Error!</h1>\n";
   echo "You are not currently logged in, logout failed. Go to <a href=\"login.php\">Login.</a>";
}
else{
if ($_SESSION['type'] = 1){
$pirepuser = $_POST ['pirepuser'];
if(isset($_POST['edit'])){
$dbserver = "";
						$dbname   = "";
						$dbname2  = "";
						$dbuser   = "";
						$dbpass   = "";
						$con = mysql_connect($dbserver, $dbuser, $dbpass) or trigger_error(mysql_error(),E_USER_ERROR);
						mysql_select_db($dbname,$con);
if ($_POST['edit'] == 'accept'){
$query2231 = "UPDATE flights SET type = '0'";
mysql_query($query2231,$con);

}
elseif($_POST['eidt'] =='delete'){
$query2232 = "UPDATE flights SET type = '2'";
mysql_query($query2232,$con);
}
mysql_close($con);
}
elseif(isset($_GET['checkpirep'])){
mysql_select_db($database_LeadHost, $LeadHost);
$result2 = mysql_query("SELECT * FROM `flights` WHERE `flight_id`='{$flightid}'");

if (mysql_num_rows($result2) > 0) {
    
    while($row = mysql_fetch_array($result2)){

						  if($row['type'] == 0){
						  $colour = 'E7E7E7';
						  }
						  elseif($row['type'] == 2){
						  $colour = 'FF5555';
						  }
						  else
						  {
						  $colour = 'F4F4F4';
						  }
echo "<td align='center' valign='middle' bgcolor='#".$colour."'><a href='../flights.php?searchfield=". $row['flight_id']."&search=Search+Flights' class='style17'>" . $row['flight_id'] . "</a></td>"; ?>
<?php echo "<td align='center' valign='middle' bgcolor='#".$colour."'>" . $row['departure'] . "</td>"; ?>
<?php echo "<td align='center' valign='middle' bgcolor='#".$colour."'>" . $row['destination'] . "</td>"; ?>
<?php echo "<td align='center' valign='middle' bgcolor='#".$colour."'>" . $row['aircraft'] . "</td>"; ?>
<?php echo "<td align='center' valign='middle' bgcolor='#".$colour."'>" . $row['totaltime'] . "</td>"; ?>
<?php echo "<td align='center' valign='middle' bgcolor='#".$colour."'>" . $row['date'] . "</td>"; ?>
<?php echo "<td align='center' valign='middle' bgcolor='#".$colour."'>" . $row['online'] . "</td>"; ?>
                              </tr><form action="<?php $PHP_SELF; ?>" method="post">
<input name="pirepuser" type="hidden" value="<?php $row32['user']; ?>" /><input name="edit" type="button" value="accept" />
<input name="edit" type="button" value="delete" /></form>
<?php
}}else( /* Line 333 */
?>
<form action="<?php $PHP_SELF; ?>" method="get"><select name="userid">
  <option value="Select One" <?php if (!(strcmp("Select One", $row_usersirep['user']))) {echo "selected=\"selected\"";} ?>>0</option>
</select><input name="checkpirep" type="button" value="Check Pirep" /></form>
<?
}

}
}}



?>

Link to comment
Share on other sites

I found something I -think- is an error, and it may or may not be related to your issue.

 

Right on Line 333

}}else( /* Line 333 */

 

You've got a ( where you should have a {.

 

See if that changes anything.

 

-Steve

Link to comment
Share on other sites

I found something I -think- is an error, and it may or may not be related to your issue.

 

Right on Line 333

}}else( /* Line 333 */

 

You've got a ( where you should have a {.

 

See if that changes anything.

 

-Steve

 

LMAO

 

Steve, you are a genius.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.