473,473 Members | 1,484 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Sample of reading mail

Is there some code example how to read/send e-mail with PHP ?
Beside this i need to pull out the attachment and to save it in some
directory.

Any idea?
Sep 24 '08 #1
3 1774
Intos wrote:
Is there some code example how to read/send e-mail with PHP ? Beside
this i need to pull out the attachment and to save it in some directory.
How do you receive the email? POP3, mbox, IMAP, MAPI, Webmail, Maildir?

Sending mail can be done with mail().
Sep 24 '08 #2
On 24 Sep, 06:52, "Intos" <in...@mail.comwrote:
Is there some code example how to read/send e-mail with PHP ?
Beside this i need to pull out the attachment and to save it in some
directory.

Any idea?
Anything wrong with the first 2 articles listed in the Google search
of:
php read email attachment
???
Sep 24 '08 #3

"Intos" <in***@mail.comha scritto nel messaggio
news:gb**********@localhost.localdomain...
Is there some code example how to read/send e-mail with PHP ?
Beside this i need to pull out the attachment and to save it in some
directory.

Any idea?
I cannot write down a full sample, that would be a bit long.

You should parse the received message in the part of the attachments, detect
the transfer encoding and decode the attached file(s).

A document about decoding the Attachments
http://pages.prodigy.net/michael_santovec/decode.htm

A decent attachment decoder (from scratch) will require you hours of work.

You can give a look at portions of code of the various php webmail
(uebimiau, nocc, atmail, etc) scripts
or crms like sugarcrm. They all should include a mime recognition and the
complete parsing/decoding of the emails.
Regards
L. A. Iarrusso

http://www.j2be.com
Sep 24 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Ashish Kanoongo | last post by:
Does anyone have an example of field mapping? I am trying to write an app that reads a .csv file and then allows a user to map those .csv fields to existing SQL fields... I have the...
4
by: Chad Benjamin via SQLMonster.com | last post by:
Hello, Im brand new and trying to learn SQL Server 2000, I have purchased a book and been reading it for a few weeks. I'm tring to find an ASP script that would let me know if my connection to...
4
by: Vittal | last post by:
Hello, Here I have a simple C program. But I am not understanding how I can debug this? #include <stdio.h> main() { int pid=0; pid=fork();
4
by: Nick | last post by:
Hi, Any sample code which test the encoding of a text file? Most results I found in google is : unless you read the file, you will never know the encoding, but the problem is I need to tell...
6
by: Peter | last post by:
I'm interested to know what ideas are out there for reading a parallel port at a constant sample rate while still allowing the user to interact with the GUI. That is, reading it every 10ms for...
4
by: Al G | last post by:
Has anyone played with MS's SMTP sample, mailer.exe? I downloaded the sample, and ran it, but keep getting the error "Failure sending mail". Where might I look for more information? Maybe some...
1
by: CodeSeeker | last post by:
I have an application, which uses pop3 to read the messages from the mailbox, and it has been working fine for so many year. We recently have started changing this application to use java mail IMAP 4...
4
by: John | last post by:
Hi Outlook 2003 connected with exchange server. A user is logged in to the client pc. Is it possible to programmatically get the user's email address that is set on the 'Email Addresses' tab...
6
by: WT | last post by:
Hello, Using url rewritting and ajax.net, I tried to circumvent some potential problems with postback url using a code from a sample given by Scott. The idea is to use a control Adapter on...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.