RE: [PHP] mail() question
| From: | Peter Houchin | Date: | Wed, 28 Feb 2001 00:00:55 +0000 |
| Subject: | RE: [PHP] mail() question | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-41918@lists.php.net to get a copy of this message | ||
Set your mail script up something like
//open the file
$myfile= file("data.txt");
//put file contents into one string
$myfile = implode($myfile, "");
$mailTo = "whateva@whateva.com"; // if its going to more than one use a
comma after "
$mailSubject = "some subject"; // subject of email
$mailBody = $myfile // call in $myfile
$mailHeaders "From: you@youremail.com\n"; add mail headers here
mail($mailTo, $mailSubject, $mailBody, $mailHeaders);
& your done
I can't see why this wouldn't work for you
Peter
-----Original Message-----
From: W.D. [mailto:suedeuno@yahoo.com]
Sent: Wednesday, February 28, 2001 10:34 AM
To: Peter Houchin; php-general@lists.php.net
Subject: Re: [PHP] mail() question
just the info in the .txt file
> did you want to actually send the .txt file or just the info in the .txt
> file??
>
> -----Original Message-----
> From: W.D. [mailto:suedeuno@yahoo.com]
> Sent: Wednesday, February 28, 2001 10:19 AM
> To: php-general@lists.php.net
> Subject: [PHP] mail() question
>
>
> I want to send a .txt file back to the sender when a form is filled out,
> sort of like an autoresponder. I have one mail() to send info from form to
> me, is the only way to send out a file back to the sender by using a
second
> mail()?
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com