Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Old 04-17-2010, 03:35 PM PHP form on godaddy
Junior Talker

Posts: 4
Name: Mike
Trades: 0
Hi,

I'm a newbie to PHP. I have two php forms on a flash website hosted on godaddy. One form is an order form and the other is email. The order form was working but not the email. I fixed the email form but now the order form is no longer working. Any advice is much appreciated.

Here's the code for the order form:

<?php

ini_set('sendmail_from', 'user@domain.tld'); // Set only on Windows
ini_set('SMTP', 'relay-hosting.secureserver.net');

$senderName = $_POST['userName'];
$senderEmail = $_POST['userEmail'];
$senderAddress = $_POST['userAddress'];
$senderCountry = $_POST['userCountry'];
$senderCity = $_POST['userCity'];
$senderProductlist1 = $_POST['userProductlist1'];
$senderUnits = $_POST['userUnits'];
$senderGrip1 = $_POST['userGrip'];
$senderProductlist2 = $_POST['userProductlist2'];
$senderUnits1 = $_POST['userUnits1'];
$senderGrip2 = $_POST['userGrip1'];
$senderProductlist3 = $_POST['userProductlist3'];
$senderUnits2 = $_POST['userUnits2'];
$senderGrip3 = $_POST['userGrip2'];
$senderServicelist1 = $_POST['userServicelist1'];
$senderUnits3 = $_POST['userUnits3'];
$senderServicelist2 = $_POST['userServicelist2'];
$senderUnits4 = $_POST['userUnits4'];
$senderMainString = $_POST['userMainString'];
$senderTensionMain = $POST['userMaintension'];
$senderCrossString = $_POST['userCrossString'];
$senderTensionCross = $POST['userCrosstension'];



$senderName = stripslashes($senderName);
$senderEmail = stripslashes($senderEmail);
$senderAddress = stripslashes($senderAddress);
$senderCountry = stripslashes($senderCountry);
$senderCity = stripslashes($senderCity);



$to = "sales@acetennispro.ca";
$from = "$senderEmail";
$subject = "WebOrder";

$message = "Results from the form";

Name: $senderName
Email: $senderEmail
Addres: $senderAddress
Country: $senderCountry
City: $senderCity
Productlist1: $senderProductlist1
Units: $senderUnits
Grip1: $senderGrip1
Productlist2: $senderProductlist2
Units1: $senderUnits1
Grip2: $senderGrip2
Productlist3: $senderProductlist3
Unit2s: $senderUnits2
Grip3: $senderGrip3
ServiceList1: $senderServicelist1
Units4: $senderUnits4
ServiceList2: $senderServicelist2
Units5: $senderUnits5
MainString: $senderMainString
TensionMain: $senderTensionMain
CrossString: $senderCrossString
TensionCross: $senderTensionCross



$senderMessage";

$headers = "From: $from\r\n";
$headers .= "Content-type: text\r\n";
$to = "$to";

mail($to, $subject, $message, $headers);


$my_msg = "Thanks $senderName, your order has been sent.An invoice will be sent in 24 hrs.";

print "return_msg=$my_msg";

exit();
?>
catac73 is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 04-17-2010, 04:52 PM Re: PHP form on godaddy
lynxus's Avatar
Awesomeo-Maximo

Posts: 1,618
Location: UK
Trades: 1
Just out of interest when you run the page, Do you get any errors in your webserver log files?

That may help pinpoint where the issue lies.
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


lynxus is offline
Reply With Quote
View Public Profile Visit lynxus's homepage!
 
Old 04-17-2010, 04:56 PM Re: PHP form on godaddy
Junior Talker

Posts: 4
Name: Mike
Trades: 0
no.no error message.
catac73 is offline
Reply With Quote
View Public Profile
 
Old 04-17-2010, 05:03 PM Re: PHP form on godaddy
lynxus's Avatar
Awesomeo-Maximo

Posts: 1,618
Location: UK
Trades: 1
humm
Do both forms post to the same php file?

I cant see anything jumping out at me.
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


lynxus is offline
Reply With Quote
View Public Profile Visit lynxus's homepage!
 
Old 04-17-2010, 05:05 PM Re: PHP form on godaddy
lynxus's Avatar
Awesomeo-Maximo

Posts: 1,618
Location: UK
Trades: 1
Ah ha,
Maybe its this bit...

Code:
$message = "Results from the form";

Name: $senderName 
Email: $senderEmail
Addres: $senderAddress
Country: $senderCountry
City: $senderCity
Productlist1: $senderProductlist1
Units: $senderUnits
Grip1: $senderGrip1
Productlist2: $senderProductlist2
Units1: $senderUnits1
Grip2: $senderGrip2
Productlist3: $senderProductlist3
Unit2s: $senderUnits2
Grip3: $senderGrip3
ServiceList1: $senderServicelist1
Units4: $senderUnits4
ServiceList2: $senderServicelist2
Units5: $senderUnits5
MainString: $senderMainString
TensionMain: $senderTensionMain
CrossString: $senderCrossString
TensionCross: $senderTensionCross



$senderMessage";
Name: $senderName
has no " " or ending semicolons,

The bottom sendermessage only has one "
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


lynxus is offline
Reply With Quote
View Public Profile Visit lynxus's homepage!
 
Old 04-17-2010, 05:08 PM Re: PHP form on godaddy
lynxus's Avatar
Awesomeo-Maximo

Posts: 1,618
Location: UK
Trades: 1
Id probably change to:

Code:
$message = 'Results from the form \n


Name: $senderName 
Email: $senderEmail
Addres: $senderAddress
Country: $senderCountry
City: $senderCity
Productlist1: $senderProductlist1
Units: $senderUnits
Grip1: $senderGrip1
Productlist2: $senderProductlist2
Units1: $senderUnits1
Grip2: $senderGrip2
Productlist3: $senderProductlist3
Unit2s: $senderUnits2
Grip3: $senderGrip3
ServiceList1: $senderServicelist1
Units4: $senderUnits4
ServiceList2: $senderServicelist2
Units5: $senderUnits5
MainString: $senderMainString
TensionMain: $senderTensionMain
CrossString: $senderCrossString
TensionCross: $senderTensionCross

';

$senderMessage"";
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE


lynxus is offline
Reply With Quote
View Public Profile Visit lynxus's homepage!
 
Old 04-17-2010, 07:51 PM Re: PHP form on godaddy
Junior Talker

Posts: 4
Name: Mike
Trades: 0
done and still nothing.i have absolutely no idea what could be wrong.
catac73 is offline
Reply With Quote
View Public Profile
 
Old 04-17-2010, 08:33 PM Re: PHP form on godaddy
Junior Talker

Posts: 4
Name: Mike
Trades: 0
thanks for your help. i fixed it.
catac73 is offline
Reply With Quote
View Public Profile
 
Old 05-10-2010, 11:02 PM Re: PHP form on godaddy
Junior Talker

Posts: 1
Trades: 0
catac73 - what was your fix to this issue - im having similar issues with godady

thx
datavoltron is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to PHP form on godaddy
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.29800 seconds with 12 queries