Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PHP contact form

Status
Not open for further replies.
I should say that i didn't touch line 25.
I left it as it was.
Thanks
 
this is a register globals issue. the code is not very well crafted and is archaic. read up on the topic in the FAQs and in the php.net website.

for the purposes of learning ONLY shove the following lines as the first few lines of code in your send_contact.php script

Code:
foreach ($_POST as &$val):
 $val = trim($val);
 if (!get_magic_quotes_gpc()):
   $val = addslashes($val);
 endif;
endforeach;
extract ($_POST);

then continue your code as was.

this is a very quick and dirty fix and still leaves your code exposed in a nasty way.
 
Hi !
I made a form using dreamweaver.
The problem is this.

Could not connect to Hotmail as %s.
Hotmail no longer allows email access via Outlook Express for free email accounts.
Account: 'Hotmail', Server: ' Protocol: HTTPMail,
Server Response: 'Access to Hotmail via Outlook and Outlook Express now requires a subscription.
Please sign up at Port: 0, Secure(SSL): No, Error Number: 0x800CCCF6
 
so what's the problem? you're being told by hotmail that they don't support pop/imap access without payment. so if you want to use pop/imap then you need to pay them some money! i think this also extends to use of http where the referrer is not an address within the hotmail domain.
 
Hi jpadie !
I changed the adress of the receiving party so that it does not go to hot mail.
I made it like this
For example
"mailto:jpadie@tek-tips.com"
And I am still getting the same message.
I don't know why i am having so much problem with such a simple thing.

Thanks
 
what is your default smtp server in your php.ini file?
 
Hi jpadie !
I really don't know what that means.
All what to do is make a simple form.
To receive customer information.
Thanks
 
email has to be sent out of an smtp server (usually). if you use the mail() function within php it uses the default smtp server specified in php.ini (on windows); on unix it uses sendmail and you must specify the path.

if you are hosting this site on your own computer look in the php.ini file for the answer (you can also get the information from the function phpinfo();). if you are hosting on a shared server, contact your ISP.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top