svenjcvd Posted March 31, 2010 Share Posted March 31, 2010 svenjcvd Irregular parse error in C:\wamp\www\eigenofferte3.php on line 13... « on: Today at 08:04:31 AM »QuoteI get an error on line 13... What am i doing wrong?? Maybe its not the only error.... Thank you.. HTML.JPG (56.33 kB, 813x626 - viewed 3 times.) PHP.JPG (57.5 kB, 803x622 - viewed 4 times.) Report to moderator 94.210.90.6 -------------------------------------------------------------------------------- thorpe Staff Alumni 'Mind Boggling!' Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #1 on: Today at 08:07:48 AM »QuoteIf statements do not end with ;Report to moderator Logged Patience is like bread I say, I ran out of that yesterday. http://thorpesystems.com Debian :: Funtoo :: Hudzilla :: Rute :: How To Ask? -------------------------------------------------------------------------------- isedeasy Enthusiast Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #2 on: Today at 08:08:04 AM »Quoteremove the semi-colon from the end of line 7Report to moderator Logged I <3 Memcache -------------------------------------------------------------------------------- svenjcvd Irregular Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #3 on: Today at 08:16:41 AM »Quoteyou' re right about that patience... but i am patienced, im just not good in this language... Now i removed the ; from line 7 and the line 13 error is gone.. but now i get another error on line 16... maybe the cause of removing ; on line 7 ? Can someone please check my script? Thanks...Report to moderator 94.210.90.6 -------------------------------------------------------------------------------- isedeasy Enthusiast Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #4 on: Today at 08:33:30 AM »QuoteCan you tell us what the error is? where is the variable $email coming from? It looks like an old script that makes use of register_globals being set to on. try adding $email = $_POST['email']; at the top of your script. Report to moderator Logged I <3 Memcache -------------------------------------------------------------------------------- svenjcvd Irregular Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #5 on: Today at 08:45:23 AM »Quote Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #4 on: Today at 08:33:30 AM »QuoteCan you tell us what the error is? where is the variable $email coming from? It looks like an old script that makes use of register_globals being set to on. try adding $email = $_POST['email']; at the top of your script. ----------------------------- It told me " Parse error: parse error in C:\wamp\www\eigenofferte3.php on line 14" ... now i have added $email = $_post('email'); at the top and i says.. Parse error: parse error in C:\wamp\www\eigenofferte3.php on line 17 this is my script now.. PHP.JPG (53.3 kB, 801x598 - viewed 4 times.) Report to moderator 94.210.90.6 -------------------------------------------------------------------------------- isedeasy Enthusiast Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #6 on: Today at 08:53:03 AM »Quotewell I cant really tell by the image but does line 15 read else ( or else { Report to moderator Logged I <3 Memcache -------------------------------------------------------------------------------- svenjcvd Irregular Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #7 on: Today at 08:58:50 AM »Quoteit reads else ( Report to moderator 94.210.90.6 -------------------------------------------------------------------------------- thorpe Staff Alumni 'Mind Boggling!' Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #8 on: Today at 08:59:46 AM »QuoteThen fix it.Report to moderator Logged Patience is like bread I say, I ran out of that yesterday. http://thorpesystems.com Debian :: Funtoo :: Hudzilla :: Rute :: How To Ask? -------------------------------------------------------------------------------- svenjcvd Irregular Re: parse error in C:\wamp\www\eigenofferte3.php on line 13... « Reply #9 on: Today at 09:15:51 AM »Quotei ve now changed the ( into a { ... the error is gone, but now it gives me another one.. Same error but on line 20.. i think it was the }so ive removed it, line 20 is good, but then it says Parse error: parse error in C:\wamp\www\eigenofferte3.php on line 23 This is making me sooo angry.... damn .. starting on line 14: else { // email validation if(!eregi('^([._a-z0-9-]+[._a-z0-9-]*)@(([a-z0-9-]+\.)*([a-z0-9-]+)(\.[a-z]{2,3})?)$', $email)) { print ("Dit is geen geldig emailadres, probeer het opnieuw a.u.b."); exit // send email $headers = "From: \"$naam\" <$email>\n"; $subject = "Nieuwe offerte"; $message = "$naam". "$adres". "$postcodeplaats". "$tel". "$fax". "$email". "$offerteaanvraag"; mail ("[email protected]", "$Naam", $adres, $postcodeplaats); print ("Bedankt $naam, Uw bericht is verzonden, we nemen zo spoedig mogelijk contact met je op!"); } ?> BTW what does the $email = $_POST['email']; meens? [attachment deleted by admin] Link to comment https://forums.phpfreaks.com/topic/197114-error-line-23/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.