crj900 Posted May 12, 2009 Share Posted May 12, 2009 I have a several PHP forms on my website that is hosted with Godaddy. They were working for 3 weeks and they randomly stopped. They told me it was because I needed to add 'secure-relayhostingserver' to my script so they blocked them. Does anyone know how to fix this? It is really upsetting me and I need the help fast. Please help. Thanks. <?php // get posted data into local variables $EmailFrom = Trim(stripslashes($_POST['EmailFrom'])); $EmailTo = "[email protected]"; $Subject = "Nova Leap Proposal"; $Name = Trim(stripslashes($_POST['Name'])); $CompanyName = Trim(stripslashes($_POST['CompanyName'])); $Phone = Trim(stripslashes($_POST['Phone'])); $Tellusaboutyourproject = Trim(stripslashes($_POST['Tellusaboutyourproject'])); // validation $validationOK=true; if (Trim($EmailFrom)=="") $validationOK=false; if (!$validationOK) { print "<meta http-equiv=\"refresh\" content=\"0;URL=error.htm\">"; exit; } // prepare email body text $Body = ""; $Body .= "Name: "; $Body .= $Name; $Body .= "\n"; $Body .= "CompanyName: "; $Body .= $CompanyName; $Body .= "\n"; $Body .= "Phone: "; $Body .= $Phone; $Body .= "\n"; $Body .= "Tellusaboutyourproject: "; $Body .= $Tellusaboutyourproject; $Body .= "\n"; // send email $success = mail($EmailTo, $Subject, $Body, "From: <$EmailFrom>"); // redirect to success page if ($success){ print "<meta http-equiv=\"refresh\" content=\"0;URL=services.html\">"; } else{ print "<meta http-equiv=\"refresh\" content=\"0;URL=error.htm\">"; } ?> Link to comment https://forums.phpfreaks.com/topic/157764-php-form-not-working-with-godaddy/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.