-
Attach file to email
I'm trying to create an online application for some job positions. I have feilds like name email and the like and then it sends an email to or recruiter.
the problem i'm getting is how to allow the user to attach there resume (.doc or .pdf)
as i understand it
1) the user uses a form object to browse to the location
2)?????
3) i break the file up into basicly text
4) wrap the "text" in some headers to let the email know its an attachment
5) i append that wrapped text to the header string
6) send the email
7) profit!
I think i have a fairly firm undertanding of 1 and 4-7 but how to get the file to the server and how to read it is something i just cant seem to find on google
thanks if you can help me
-
Re: Attach file to email
PHP will let you upload files via a form. the examples on PHP.net are pretty good.
I don't think you can't easily break a doc or pdf file into text, though, so.. you may want to skip that.
edit: oh, I didn't even realize you were asking about email attachments. handling them with mail() is a real pain, so I suggest you use the PHPMailer class or something instead. I hear they're pretty easy to use.