I am trying to get this form to work but at fusionoutside (dot)co(dot)uk/contact us I am experinced with html but not php Below is a script which is not forwarding an email <?php $Name = $_POST['Name']; $Lastnname = $_POST['Lastname']; $Title = $_POST['Title']; $Email = $_POST['Email']; $Phone = $_POST['Phone']; $Email = $_POST['Email']; $Enquiry = $_POST['Enquiry']; die ("Thank you for contacting us we will contact you soon!! "); { if(!$Email == "" && (!strstr($Email,"@") || !strstr($Email,"."))) { echo "<h2>Use Back - Enter valid e-mail</h2>\n"; $badinput = "<h2>Feedback was NOT submitted</h2>\n"; echo $badinput; die ("Go back! ! "); } if(empty($Name) || empty($Email)) { echo "<h2>Use Back - fill in all fields</h2>\n"; die ("Use back! ! "); } $todayis = date("l, F j, Y, g:i a") ; $notes = stripcslashes($notes); $message = " $todayis [EST] \n Name: $Name \n Last name: $Lastname \n Email: $Email \n Phone Number: $Phone \n Email: $Email \n Enquiry: $Enquiry \n "; $from = "From: "; mail("info@fusionoutside.co.uk", $subject, $message, $from); ?> I know the characters (name,last name are not matching) but it was just me changing things around trying to find a solution to no success YOUR INPUT WILL BE GREATLY APPRECIATED
I am doing everything ONLINE I am getting everything on a browser in fact here is a changed code : <?php $Name = $_POST['Name']; $Lastnname = $_POST['Lastname']; $Company = $_POST['Company']; $Title = $_POST['Title']; $Email = $_POST['Email']; $Telephone = $_POST['Telephone']; $Mobile = $_POST['Mobile']; $Event = $_POST['Event']; $Enquiry = $_POST['Enquiry']; die ("Thank you for contacting us we will contact you soon!! "); { if(!$Email == "" && (!strstr($Email,"@") || !strstr($Email,"."))) { echo "<h2>Use Back - Enter valid e-mail</h2>\n"; $badinput = "<h2>Feedback was NOT submitted</h2>\n"; echo $badinput; die ("Go back! ! "); } if(empty($Name) || empty($Email)) { echo "<h2>Use Back - fill in all fields</h2>\n"; die ("Use back! ! "); } $todayis = date("l, F j, Y, g:i a") ; $notes = stripcslashes($notes); $message = " $todayis [EST] \n Name: $Name \n Last name: $Lastname \n Company: $Company \n Title: $Title\n Email: $Email \n Telephone: $Telephone \n Mobile: $Mobile \n Enquiry: $Enquiry \n "; $from = "From: "; mail("info@fusionoutside.co.uk",$subject, $message, $from); ?> and here is the ERROR MESSAGE Parse error: syntax error, unexpected $end in \\NAS37ENT\domains\f\fusionoutside.co.uk\user\htdocs\form_process.php on line 56
comment out that line completely. /*die ("Thank you for contacting us we will contact you soon!! "); {*/ PHP: change this: mail("info@fusionoutside.co.uk",$subject, $message, $from); PHP: To: if(mail("info@fusionoutside.co.uk",$subject, $message, $from)){ print "Thank you for contacting us we will contact you soon!!" }else{ // print some error message here } PHP: Hope that helps
If that code is the whole code copied from your site it looks like $subject is never being defined - is it the same as $notes above it which looks like it isn't being used?
offtopic: why do you hide your web address to bots when you could get more backlinks but display your email address when you can loads of spam ?
This is the latest error Parse error: syntax error, unexpected $end in \\NAS37ENT\domains\f\fusionoutside.co.uk\user\htdocs\form_process.php on line 53
unexpected $end usually means we forget to close a statement some where. With your current code I would say either you may have forgotten to put a semi-colon ( or a close bracket } post the code so we can help you out.