I do not know much code but have figured out alot of the past day setting up my first site but now I am perplexed and need help.
I created the html code using NVU and like it. The issue is with a form I created to gather some information from visitors and e-mail it to myself.
I used the Form wizard to create the initial bits of PHP script. After much trial and erro and a free trial of a PHP debugger, I finally got the form to work properly.
However, when I tested the website, the form did everything perfectly EXCEPT it did not send the e-mail as the script told it to. I started to wonder if the economy go daddy wouldn't allow it. After some time with google, I discovered that go daddy has an "economy w/ASP" and an "economy w/PHP" and that I should switch to PHP, so I did so and waited several hours for the switch to happen.
When I tested the website again, IT WORKED and the e-mail was SENT. Everything looked great until I hit the refresh button on the form and it said 404 error. After some testing on other computers I realize that the form page is not coming up at all now. It just works on the one PC because the form is still in the cache from before. The home page still works just fine.
So I am completely confused. I know the "form.html" is uploaded since I used it prior to the switch and I "see" it on the host.
I know the PHP script works since it works on the cached form on my PC.
Any clues would be appreciated. I put the form.php text below.
Thanks Eric
// ------------- CONFIGURABLE SECTION ------------------------
// $mailto - set to the email address you want the form
// sent to, eg
//$mailto = "youremailaddress@example.com" ;
$mailto = "Info@ShortSaleFAQ.com" ;
// $subject - set to the Subject line of the email, eg
$subject = "Short Sale Property Form" ;
// the pages to be displayed, eg
//$formurl = "http://www.example.com/feedback.html" ;
//$errorurl = "http://www.example.com/error.html" ;
//$thankyouurl = "http://www.example.com/thankyou.html" ;
$formurl = "http://www.ShortSaleFAQ.com/form.html" ;
$errorurl = "http://www.ShortSaleFAQ.com/error.html" ;
$thankyouurl = "http://www.ShortSaleFAQ.com/thankyou.html" ;
$uself = 0;
// -------------------- END OF CONFIGURABLE SECTION ---------------
$headersep = (!isset( $uself ) || ($uself == 0)) ? "\r\n" : "\n" ;
$propertytype = $_POST ;
$propertystatus = $_POST ;
$foreclosurestatus = $_POST ;
$city = $_POST ;
$state = $_POST ;
$zip_code = $_POST ;
$bedrooms = $_POST ;
$bathrooms = $_POST ;
$sf = $_POST ;
$mortgages = $_POST ;
$forsale = $_POST ;
$lisitngprice = $_POST ;
$bankruptcy = $_POST ;
$paidtax = $_POST ;
$wishsell = $_POST ;
$repairs = $_POST ;
$mortgagebalance = $_POST ;
$fmv = $_POST ;
$howfind = $_POST ;
$referrer = $_POST ;
$name = $_POST ;
$email = $_POST ;
$comments = $_POST ;
$http_referrer = getenv( "HTTP_REFERER" );
$headers = 'From: [EMAIL="info@shortsalefaq.com'"]info@shortsalefaq.com'[/EMAIL] ;
if (empty($name) || empty($email)) {
header( "Location: $errorurl" );
exit ;
}
$messageproper =
"Name of seller: $name\n" .
"Email of seller: $email\n" .
"Property Type: $propertytype\n" .
"Property Status: $propertystatus\n" .
"Foreclosure Status: $foreclosurestatus\n" .
"City: $city\n" .
"State: $state\n" .
"Zip Code: $zip_code\n" .
"Number of Bedrooms: $bedrooms\n" .
"Number of Baths: $bathrooms\n" .
"Square Footage: $sf\n" .
"Number of Mortgages: $mortgages\n" .
"Is house For Sale?: $forsale\n" .
"What is Listing Price: $listingprice\n" .
"In Bankruptcy?: $bankruptcy\n" .
"Paid Property tax?: $paidtax\n" .
"All Wish to Sell?: $wishsell\n" .
"Need repairs?: $repairs\n" .
"Mortgage Balance: $mortgagebalance\n" .
"Fair Market Value: $fmv\n" .
"How did you find us?: $howfind\n" .
"Name of Referrer: $referrer\n" .
"------------------------- COMMENTS -------------------------\n\n" .
$comments .
"\n\n------------------------------------------------------------\n" ;
ini_set("SMTP","smtp.comcast.net");
mail($mailto, $subject, $messageproper, $headers);
header("Location: http://www.shortsalefaq.com/thankyou.html");
exit ;
?>