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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

send mail is not working help please

Status
Not open for further replies.

cs7536

Programmer
Joined
Apr 20, 2003
Messages
130
Location
US
I have a script that I created on php..

<?php mail(&quot;mviana@corporatestreet.net&quot;, &quot;Registration&quot;,
&quot;First Name: $fname
Last Name: $lname
Address: $address
City: $city
State: $state
Zip Code: $zip
Gender: $gender
Age: $age
Phone1: $phone1
Phone2: $phone2
E-mail1: $email1
E-mail2: $email2&quot;); ?>

the script works on php servers I try it on but will not work on mine.. can some one halp


I am useing apache 1.3 and php 4.0
 
out look is not able to send mail through the local mailer server, but will send mail through my isp.
 
let me try it now hold on
 
I configured php using: mail.corporatestreet.net

and the form went through but failed displayinh the following:


Notice: Undefined variable: fname in c:\program files\apache group\apache\htdocs\fanmail.php on line 15
Thank You We Will Keep You Informed With Updates, Products And News


Notice: Undefined variable: fname in c:\program files\apache group\apache\htdocs\fanmail.php on line 26

Notice: Undefined variable: lname in c:\program files\apache group\apache\htdocs\fanmail.php on line 27

Notice: Undefined variable: address in c:\program files\apache group\apache\htdocs\fanmail.php on line 28

Notice: Undefined variable: city in c:\program files\apache group\apache\htdocs\fanmail.php on line 29

Notice: Undefined variable: state in c:\program files\apache group\apache\htdocs\fanmail.php on line 30

Notice: Undefined variable: zip in c:\program files\apache group\apache\htdocs\fanmail.php on line 31

Notice: Undefined variable: gender in c:\program files\apache group\apache\htdocs\fanmail.php on line 32

Notice: Undefined variable: age in c:\program files\apache group\apache\htdocs\fanmail.php on line 33

Notice: Undefined variable: phone1 in c:\program files\apache group\apache\htdocs\fanmail.php on line 34

Notice: Undefined variable: phone2 in c:\program files\apache group\apache\htdocs\fanmail.php on line 35

Notice: Undefined variable: email1 in c:\program files\apache group\apache\htdocs\fanmail.php on line 36

Notice: Undefined variable: email2 in c:\program files\apache group\apache\htdocs\fanmail.php on line 36

 
It's probably the setting of register_globals in php.ini. Set it to on, restart Apache, and try it. If it works, that's the problem.

However, I recommend that you write code that does not depend on the value of register_globals. Instead of referencing the variables $<form name>, reference $_POST['<form name>'] or $_GET['<form name>']

For more information:


Want the best answers? Ask the best questions: TANSTAAFL!
 
that did something possitive cause now I get this:

Thank You mmmmm We Will Keep You Informed With Updates, Products And News


Warning: mail() [function.mail]: SMTP server response: 550 User not local. We don't relay in c:\program files\apache group\apache\htdocs\fanmail.php on line 36

 
Then your ISP's server is, for some reason, not relaying for your script. Does it relay to the same destination address from the same recipient address for Outlook?

You may run into some problems with this script. Your ISP obviously correctly has relay restrictions on their server. They may also not allow your local mail server to send outside their network, once you get it running.

Before continuing from this point, you should talk with your ISP's tech support.

I'm signing off -- it's nearly midnight where I am.

Good luck...

Want the best answers? Ask the best questions: TANSTAAFL!
 
thank you so much for your time and knowledge
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top