Page 1 of 1
How to email data into a database, need help...
Posted: Wed May 28, 2008 5:07 pm
by WithHisStripes
Heya,
So I am working on a website that I'm going to write a simple CMS for, and I recall seeing blogging systems that allowed the user to submit a blog into the database by just emailing it to a particular address.
I assume PHP somehow parses the data and then wraps some MySQL INSERT statements around it or something, but I don't really know where to begin, does anyone have experience with this? Thanks!
Re: How to email data into a database, need help...
Posted: Wed May 28, 2008 6:07 pm
by califdon
WithHisStripes wrote:Heya,
So I am working on a website that I'm going to write a simple CMS for, and I recall seeing blogging systems that allowed the user to submit a blog into the database by just emailing it to a particular address.
I assume PHP somehow parses the data and then wraps some MySQL INSERT statements around it or something, but I don't really know where to begin, does anyone have experience with this? Thanks!
The trouble is, email is a totally different system and protocol. No doubt there's a way to use some programming language (I would expect, not PHP) to make regular checks of the content of a POP3 or IMAP server and process it, but I think probably the reason for doing it that way would be to interject human decision making into the process. Is there some reason why you don't want to just use an online form? That is straightforward and there's copious amounts of info available on doing that.
Re: How to email data into a database, need help...
Posted: Thu May 29, 2008 5:15 pm
by WithHisStripes
You know I didn't consider that PHP wouldn't be able to do it, so thanks for bringing that to my attention.
No particular reason I wanted the client to be able to do it via email except to learn something new and see how it might improve a site.
I guess that was the answer I'm looking for, so thanks for your reply!