Ohio Guy Posted October 28, 2009 Share Posted October 28, 2009 When I first upload my php files, they work for awhile. Then, I will get this error. Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/wwwcoup/public_html/couponscript5/couponsite/index.php on line 126 When I check that line, nothing is on that line. When I upload the exact same file without any changes, it will work fine for awhile and then I get the error again. What is causing this? Thanks, Tom Quote Link to comment Share on other sites More sharing options...
abazoskib Posted October 28, 2009 Share Posted October 28, 2009 Its telling you what's wrong. Do you find that it doesn't work after editing the file? Maybe you have misplace single or double quotes, or you are missing a semi colon. Quote Link to comment Share on other sites More sharing options...
Ohio Guy Posted October 29, 2009 Author Share Posted October 29, 2009 I don't make any changes to the file. I just upload it again and it works fine for awhile. Then I get an error code. I did make a change this time. I deleted a empty line because that is the line that was referred to in the error. Now when it doesn't work, I get this error. Fatal error: Cannot redeclare vzoc() (previously declared in /home/wwwcoup/public_html/internet/couponsite/index.php(1) : eval()'d code:1) in /home/wwwcoup/public_html/internet/couponsite/functions.php(1) : eval()'d code on line 1 It works for a while and then doesn't. One other thing. I have this code in 2 different directories. When one works, the other works also. If I get an error on one, when I go to the other, I get an error on it also. Then I upload the same file to both and it works again for awhile. Thanks, Tom Quote Link to comment Share on other sites More sharing options...
Ohio Guy Posted November 1, 2009 Author Share Posted November 1, 2009 I have replaced the 2 php scripts that are causing the problems with the original scripts which didn't cause any problems for about 6 weeks. I get this error. Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/wwwcoup/public_html/couponscript5/couponsite/index.php on line 169 and if I upload the index.php, I get this error message. Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/wwwcoup/public_html/couponscript5/couponsite/index.php on line 242 I still have the same problem. This is the index script lines 154 to 178. The error is in line 169 which is the blank line below this line. if ($page=="signup2") {include ("signup.php");} ///////////////////////////////////////////////////////// // Sign Up Ad, gives details about signing up etc... ///////////////////////////////////////////////////////// if ($page=="signup1") {include ("signup.php");} ///////////////////////////////////////////////////////// // Sign primary form, info goes into 'users' table ///////////////////////////////////////////////////////// if ($page=="signup2") {include ("signup.php");} ///////////////////////////////////////////////////////// // Create user, billing=0 not paid expired yesterday ///////////////////////////////////////////////////////// if ($page=="signup3") {include ("signup.php");} The other file doesn't have a line 242 but it has to be replaced and the error message says that the error is in line 242. This is the code from the index.php file. while ($row=mysql_fetch_object($result)) { if (isDateExpired($row->expire)) { continue; } The last } is line 242. Can anyone help me fix this problem? Thanks, Tom Quote Link to comment Share on other sites More sharing options...
abazoskib Posted November 1, 2009 Share Posted November 1, 2009 I would say post the whole code, if not more surrounding code. The error is obviously not the blank line. Quote Link to comment Share on other sites More sharing options...
Ohio Guy Posted November 1, 2009 Author Share Posted November 1, 2009 Here is the entire index.php code. ***SNIPPED BY akitchin: we are not going to read 2389120389021 lines of code. try to narrow it down, and please use code tags.*** I also have to load the maincontent.php to correct that section. Do you also need that code? Thanks, Tom Quote Link to comment Share on other sites More sharing options...
Ohio Guy Posted November 3, 2009 Author Share Posted November 3, 2009 I think that I solved the problem. I have had any error messages since I made this change. In the signup.php, I changed the <font size=5><B> Sign Me Up Now >> </a> to <font size=5><B> Sign Me Up Now! </a> Here is the old php file. <? //get _GET $step = $page; ///////////////////////////////////////////////////////// // Sign Up Ad, gives details about signing up etc... ///////////////////////////////////////////////////////// if ($step=="signup1") { $cost = $cfg ["monthly_cost"]; echo "<h1>Sign up here<BR><font size=2><B>Internet Business Section.</font></h1><B><font size=4> Get a membership which allows you to post an unlimited number of coupons for one year.<p> <table width=65%><div align=left> You have complete control over your coupons and advertising.<UL> <LI>No more misprinted coupons with the wrong phone number, wrong product, or wrong price. <LI>Make your changes instantly. <LI>Make your special offer available immediately. <LI>When coupons expire, they are removed automatically. <LI>Have your own page with your coupons on it.</div></table> <P>"; echo "<a href='http://www.couponfile.net/internet/couponsite/index.php?page=signup2'><font size=5><B> Sign Me Up Now! </a> </font size><font size=4><BR />If you are using Firefox, you will not be able to sign up.<BR /> Please email us at <a href=mailto:sales@couponfile.net><font size=4>sales@couponfile.net</a> and we will invoice you and set up an account.<BR /> We apologize and we are working on fixing the problem.</font size></div>"; } ///////////////////////////////////////////////////////// // Signup primary form, info goes into 'users' table ///////////////////////////////////////////////////////// if ($step=="signup2") { Do you think that corrected the problem? Thanks, Tom Quote Link to comment 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.