开发者

Uploading photo from my website, and send it via email

I have a form, which gathers开发者_C百科 some Information of my visitor, and when they submit the Information, it will send it to my desired email. now I need another input "file" that they can even attach their photo and send along with it to my email not on my server, I have no Idea how can I do that, I would appreciate any helps.


phpmailer is a great email engine. it has many features one of which includes sending attachments. i would give this example a look, its pretty much exactly what you are trying to do.

http://zainal.wordpress.com/2007/01/10/sending-email-attachments-in-php-using-phpmailer-class/


Check out PEAR Mail_Mime for building the e-mail with attachments and optionally PEAR Mail for sending it.


Here's a link to show you how to do the file input:

http://www.cs.tut.fi/~jkorpela/forms/file.html

When you send the email, you'll have to send the file as an attachment. This link gives the idea:

http://www.webcheatsheet.com/PHP/send_email_text_html_attachment.php#attachment

(DISCLAIMER: I haven't coded PHP for a few years, so I don't know if this is the best way to do it. I just searched Google and skimmed the first link that came up).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜