f



php mail function

i have set up a feedback form that emails the results. my web host says
it will not work if the email is coming from nobody. this is their
answer "you are just going to have to learn to tell your scripts to
generate th emails as someone@yourdmain - not just as nobody."
does anyone know how to make this happen?

0
quinonez (27)
12/17/2004 2:51:13 PM
comp.lang.php 32646 articles. 0 followers. Post Follow

6 Replies
940 Views

Similar Articles

[PageSpeed] 39

Quinonez wrote:
> i have set up a feedback form that emails the results. my web host
> says it will not work if the email is coming from nobody. this is
> their answer "you are just going to have to learn to tell your
> scripts to generate th emails as someone@yourdmain - not just as
> nobody."
> does anyone know how to make this happen?

By using the fourth argument of the mail() function to send a "From: 
someone@yourdomain" header.

See: http://www.php.net/manual/en/function.mail.php


JW



0
jw137 (829)
12/17/2004 3:23:12 PM
how would i set this up?

0
quinonez (27)
12/17/2004 4:15:54 PM
On 17 Dec 2004 08:15:54 -0800, Quinonez <quinonez@gmail.com> wrote:

> how would i set this up?
>


Nothing to set up, just include the from argument:

mail('to email', 'subject', 'message', 'From: yourstruly@yourdomain.com');


-- 
Thomas

SELECT date FROM wife WHERE bitching = '0' AND sex = '1'
0
12/17/2004 4:47:33 PM
ive set this up like so

<?
mail("quinonez@gmail.com", "subject", "my message", "From:
webmaster@masterscommissioneurope.com\r\n");
?>


but im still not recieving the emails.....
the host says its because it has to be SENT from an address on the
server...wouldnt this make that possible?

0
quinonez (27)
12/17/2004 5:25:30 PM
Is the server masterscommissioneurope.com?

Mark

0
mark8915 (3)
12/17/2004 10:53:22 PM
yea i got it ....thanks

0
quinonez (27)
12/18/2004 7:30:15 PM
Reply: