Re: RE: [PHP-DB] mail()
| From: | Adam Voigt | Date: | Tue, 02 Apr 2002 16:16:38 +0000 |
| Subject: | Re: RE: [PHP-DB] mail() | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-18131@lists.php.net to get a copy of this message | ||
The last parameter of the mail command is for email headers, if you pass in
just a single email address it doesn't know what you want to do with that since
thats not a valid header. If you don't know what your doing with the last parameter
then you don't need to have it, and should omit it, as it is opitional for a reason.
If your sure you do need it, you seperate headers like this:
To set the reply-to field and the from field (as it would appear to the person who recieves
the email), you would do: "From:steve@bob.com\nReply-to:bob@bob.com"
This would make the email appear as coming from steve@bob.com, while
when they clicked the reply button, it would go to bob@bob.com, the most useful
situation for these is when your server appends a nastry from address like apache@localhost
or whatever from the webserver daemon.
Adam Voigt
adam.voigt@cryptocomm.com
On Tue, 2 Apr 2002 11:05:09 -0500 , Jamie Kupernik <Kupernik@bcn.net> wrote:
> I did try taking out the dynamic values and entering static ... Didn't
> seem to do anything. What do you mean by the "Replay-to:" thing you
> said. Can you show me an example that would fit in with mine?
>
> Thanks for responding..
>
> James
>
> -----Original Message-----
> From: Adam Voigt [mailto:adam.voigt@cryptocomm.com]
> Sent: Tuesday, April 02, 2002 11:02 AM
> To: James Kupernik
> Cc: php-db@lists.php.net
> Subject: Re: [PHP-DB] mail()
>
>
> You know that $fromaddress must have the correct header's to, right?
> Like just "test@test.com" will not be interepreted but something like
> "Reply-to:test@test.com" will set the Reply-to header correctly. Also,
> did you try taking out the dynamic values and just entering a hardcoded
> test without the variables to make sure it works just even with straight
> static values?
>
> Adam Voigt
> adam.voigt@cryptocomm.com
>
> On Tue, 2 Apr 2002 10:55:20 -0500, James Kupernik <kupernik@bcn.net>
> wrote:
> > I'm trying to run a mail function .. the program is running, but I'm
> > not getting the email. Here is the code .. any one have any ideas?
> >
> > $toaddress = $friendemail;
> >
> > $subject = "A message from ".$fromname.".";
> >
> > $mailcontent = "Here's a special message from a friend"
> > ."Your friend, ".$fromname." at ".$fromemail."
> writes:\n\n"
> > ."".$message."";
> >
> > $fromaddress = $fromemail;
> >
> > mail($fromemail, $subject, $mailcontent, $fromaddress);
> >
> > I talked with my ISP and the sendmail_path is set up correctly....
> >
> > I know it's not DB related, but I didn't know where else to turn.
> > Thanks for any help you can provide.
> >
> >
> >
> > --
> > PHP Database Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
>
>
>
> ************************************************
> This message has been scanned for computer
> viruses and none were found.
>
> Country Curtains Information Systems Department
> ************************************************
>
>
>
>
> ************************************************
> This message has been scanned for computer
> viruses and none were found.
>
> Country Curtains Information Systems Department
> ************************************************
>
>