Zepo. Posted June 21, 2007 Share Posted June 21, 2007 Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/burly/public_html/dev/admin/head.php on line 14 In <?php session_start(); if (isset($_SESSION['name'])) { echo "<html> <head> <title>Info</title> <link type='text/css' rel='stylesheet' href='./css/manage.css' /> </head> <body style='margin:0px' class='info_body'> <table border='0' width='100%' height='100%'> <tr align='center' valign='top'> <td style='text-align:left'><b>Extreme Gaming Ladder Control Panel</b> (EGL 1.0) - $_SESSION['name']</a></td> <td style='white-space:nowrap; text-align:right; font-weight:bold'> <a href="./admin.php" target="frame_main">Main</a> | <a href="../index.php" target="_blank">Home Page</a> | <a href="./logout.php" onClick="return confirm('Are you sure you want to log out of the control panel?');" target="_top">Log out</a> </td> </tr> </table> </div> </body> </html>; }else{ echo " You are not logged in! "; } ?> Quote Link to comment https://forums.phpfreaks.com/topic/56589-solved-parse-error/ Share on other sites More sharing options...
Grego Posted June 21, 2007 Share Posted June 21, 2007 Oh dear. Mi bad. Completely. Quote Link to comment https://forums.phpfreaks.com/topic/56589-solved-parse-error/#findComment-279468 Share on other sites More sharing options...
Lumio Posted June 21, 2007 Share Posted June 21, 2007 just make the quotes (") in the string to \" Quote Link to comment https://forums.phpfreaks.com/topic/56589-solved-parse-error/#findComment-279473 Share on other sites More sharing options...
Zepo. Posted June 21, 2007 Author Share Posted June 21, 2007 New Error Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/burly/public_html/dev/admin/head.php on line 6 New file <?php session_start(); if (isset($_SESSION['name'])) { echo '<html> <link type='text/css' rel='stylesheet' href='./css/manage.css' /> <body style='margin:0px' class='info_body'> <table border='0' width='100%' height='100%'> <tr align='center' valign='top'> <td style='text-align:left'><b>Extreme Gaming Ladder Control Panel</b> (EGL 1.0) </a></td> <td style='white-space:nowrap; text-align:right; font-weight:bold'> <a href='./admin.php' target='frame_main'>Main</a> | <a href='../index.php' target='_blank'>Home Page</a> | <a href='./logout.php' onClick='return confirm('Are you sure you want to log out of the control panel?');' target='_top'>Log out</a> </td> </tr> </table> </div> </body> </html>'; }else{ echo ' You are not logged in! '; } ?> Quote Link to comment https://forums.phpfreaks.com/topic/56589-solved-parse-error/#findComment-279477 Share on other sites More sharing options...
Lumio Posted June 22, 2007 Share Posted June 22, 2007 I told you to escape all quotes just make it like \' Quote Link to comment https://forums.phpfreaks.com/topic/56589-solved-parse-error/#findComment-279940 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.