pcw Posted March 17, 2009 Share Posted March 17, 2009 Hi, I keep getting this error, when trying to run this script Fatal error: Call to undefined function phpinclude() in /home/moveitho/public_html/sitebuilder/templates/members/login.php on line 1 This is my code: <?php include("../common/header.php"); include("../common/footer.php"); pageheader(); print '<table width="700" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td> </td> <td> </td> <td> </td> </tr> <tr> <td valign="top"> <form action="../../sb.php?cmd=logchk" method="post"> <input type="hidden" name="action" value="login"> <table width="300" border="1" cellpadding="0" cellspacing="0"> <tr> <td width="5" height="5"></td> <td></td> <td width="5"></td> </tr> <tr> <td></td> <td><table width="90%" border="0" cellpadding="0" cellspacing="0"> <tr> <td colspan="2"><center><h2 class="style7">Log On<br /> </h2></center> <hr /></td> </tr> <tr> <td align="right"><span class="style3">Username:</span></td> <td><input type="text" name="username"></td> </tr> <tr> <td align="right"><span class="style3">Password:</span></td> <td><input type="password" name="password"></td> </tr> <tr> <td align="right"> </td> <td align="left"><input type="submit" name="submit" value="submit"></td> </tr> <tr></tr> </table> <br /> </td> <td></td> </tr> <tr> <td height="5"></td> <td></td> <td></td> </tr> </table> </form> <br /> <table width="300" border="1" cellpadding="0" cellspacing="0"> <tr> <td width="5" height="5" ></td> <td> </td> <td width="5"></td> </tr> <tr> <td></td> <td><table width="90%" border="0" cellpadding="5" cellspacing="0"> <tr> <td><center><h2 class="style7">Not a member? </h2></center></td> </tr> <tr> <td><center><h2><a href="./sb.php">Join Up </a></h><center></td> </tr> </table> </td> <td></td> </tr> <tr> <td height="5"></td> <td></td> <td></td> </tr> </table> <p></p></td> <td width="20"> </td> <td valign="top"><br /> <br /> <h2 align="left" class="style7">Sitebuilder login page </h2> <p align="justify" class="style3"> Thank you for registering. Please login to access the members area.</p> <p align="justify" class="style3">You are free to modify this page as you wish.</p> <p align="justify" class="style3">Please follow the instruction guide, when altering the code. </p> </td> </tr> </table>'; pagefooter(); ?> What am I doing wrong? Thanks Link to comment https://forums.phpfreaks.com/topic/149796-solved-t_sl-syntax-error/ Share on other sites More sharing options...
MadTechie Posted March 17, 2009 Share Posted March 17, 2009 I can't see any problems, unless you have the script like this <?phpinclude("../common/header.php"); try commenting out both the includes (your still get errors but if you no longer get the same error remove the comment from one on the include and test again) repeat with the other include then open the included file and see if you can see the error Link to comment https://forums.phpfreaks.com/topic/149796-solved-t_sl-syntax-error/#findComment-786613 Share on other sites More sharing options...
pcw Posted March 17, 2009 Author Share Posted March 17, 2009 Hi, I removed the includes and it gave an error for undefined function phppageheader(); This doesnt make sense. The code is in this format: <?php pageheader(); So I also removed pageheader(); and now get this error Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in /home/moveitho/public_html/sitebuilder/templates/members/login.php on line 1 but line 1 is just <?php Im confused Link to comment https://forums.phpfreaks.com/topic/149796-solved-t_sl-syntax-error/#findComment-786635 Share on other sites More sharing options...
pcw Posted March 17, 2009 Author Share Posted March 17, 2009 Fixed it, for some reason it didnt like the php part of <?php, changed it to <? and it works fine. Link to comment https://forums.phpfreaks.com/topic/149796-solved-t_sl-syntax-error/#findComment-786639 Share on other sites More sharing options...
MadTechie Posted March 17, 2009 Share Posted March 17, 2009 What editor are you using ? try notepad++ (its free) open the files and check them and then re-save them the fact is says phppageheader(); would suggest that theirs no whitespace and short tags are enabled! (maybe try changing <?php to <? ) Link to comment https://forums.phpfreaks.com/topic/149796-solved-t_sl-syntax-error/#findComment-786640 Share on other sites More sharing options...
MadTechie Posted March 17, 2009 Share Posted March 17, 2009 okay well short tags are not a good thing.. try <?php again (<? php could also cause the problem) Link to comment https://forums.phpfreaks.com/topic/149796-solved-t_sl-syntax-error/#findComment-786643 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.