Jump to content

Archived

This topic is now archived and is closed to further replies.

CanMan2004

Getting file from email

Recommended Posts

Hi all

I have a email which comes in every 3 days to me, the email contains a CSV file which I have to import into a sql database, I want to try and automate this and let php

access email
pick the file from a selected email
import the file into the database

Can this be done? I'm sure it's quite complex, so any help or guidence would be great

Regards

Dave

Share this post


Link to post
Share on other sites
Why not just fetch it from your mail server (POP/IMAP), then do the insert!

Tell me the OS, mail server type (pop, imap) your doing this from, so I can tell you if you can pipe it, or if you need to login and get it from the mail server! After I'll give you a example!


me!

Share this post


Link to post
Share on other sites
Well I would do, but this is new to me, so i'm not sure how to do it.

The server is a linux server
The mail type is pop3

Thanks

Dave

Share this post


Link to post
Share on other sites
Hi

Set what as an attachment? How do I get it to automatically open the file and upload the CSV file at a chosen time.

Is it going to be more hassle than it's worth?

Share this post


Link to post
Share on other sites
Oh
I didn't realize what you wanted.  I question whether this is possible.  If it's going to your server email, I would guess set up a cron job 30-46 minutes after the email come's in to open all your email's or a bot with access information, I really have no idea.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.