generate html file by PHP script

the mail() function

Moderators: macek, egami, gesf

cerkoxxl
New php-forum User
New php-forum User
Posts: 6
Joined: Tue Jan 10, 2012 5:58 am

generate html file by PHP script

Postby cerkoxxl » Tue Jan 10, 2012 6:28 am

Hi.
I am pretty new in PHP, I do more static HTML pages fom my self an for my friends.

I am using HTML form and PHP script to sent an email with data filled in form.

Now, I want to change PHP script to not sent data in mail body, but to save data to HTML file and then sent this HTML file as attachement. So the script should create HTML file with data form HTML form, save it on server and send the HTML file either as attachement or sent a link to this file on server. And of course, every file shoud be generated with unique name.

I spent days googling without any success. Do anybody have any idea, or know some page, where is written something more about this problem?

Thanks.

User avatar
egami
php-forum GURU
php-forum GURU
Posts: 2196
Joined: Wed Oct 06, 2010 11:19 am
Location: Happy Valley, UT

Re: generate html file by PHP script

Postby egami » Tue Jan 10, 2012 6:34 am


cerkoxxl
New php-forum User
New php-forum User
Posts: 6
Joined: Tue Jan 10, 2012 5:58 am

Re: generate html file by PHP script

Postby cerkoxxl » Tue Jan 10, 2012 10:31 am

sorry, But it is nothing in your link, just google.
If you just wanted be ironical and advided me google, I really spent days by googling.

User avatar
egami
php-forum GURU
php-forum GURU
Posts: 2196
Joined: Wed Oct 06, 2010 11:19 am
Location: Happy Valley, UT

Re: generate html file by PHP script

Postby egami » Tue Jan 10, 2012 12:12 pm

You may have spent days on google searching for the answer, but it's quite obvious you didn't read any of the articles.

http://us2.php.net/manual/en/function.mail.php
Down towards the middle of the page in the user comments section, there's a complete explaination on how to do exactly what you're looking for.


So the next time you ask for help, and when you receive it, don't be so snooty.

cerkoxxl
New php-forum User
New php-forum User
Posts: 6
Joined: Tue Jan 10, 2012 5:58 am

Re: generate html file by PHP script

Postby cerkoxxl » Wed Jan 11, 2012 12:57 pm

Thank for link, I will chceck it.
I did not wanted be rude. It just was not anything in your firt link.

So, sorry and thank for the second.


Return to “PHP coding => Mail”

Who is online

Users browsing this forum: No registered users and 1 guest