473,396 Members | 2,036 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

How to read HTML email text?

I've done a couple of hours web-searching without turning up many
answers so far, and I guess I could figure it out (eventually) from
the MIME format, but here goes with my question...

I don't have any problems reading text emails, but can anybody direct
me to some PHP source code that will read (the text inside) an HTML
email, specifically the "From", "Subject" and especially the message
body?

I would like the code to be able to differentiate between (i.e. know
that it is) a text or an HTML email, and I would like the code to
ignore any attachments.

I don't expect the incoming email to have any (or large) attachments,
but I hope that any code samples can handle the possible case of big
attachments coming along for the ride.

Incidentally, if I did (not this time) want to handle large
attachments, can PHP and/or servers handle megabytes of data being
read into a string variable through fread()? I'm just getting into
this stuff, and not sure of what areas would be a resource and/or
performance hog.

Thanks in advance,

Simon.
Jul 17 '05 #1
1 4112
SimonC wrote:
I've done a couple of hours web-searching without turning up many
answers so far, and I guess I could figure it out (eventually) from
the MIME format, but here goes with my question...

I don't have any problems reading text emails, but can anybody direct
me to some PHP source code that will read (the text inside) an HTML
email, specifically the "From", "Subject" and especially the message
body?


http://pear.php.net

Kind Regards,

Ian P. Christian
Jul 17 '05 #2

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

Similar topics

3
by: NewToPHP | last post by:
I am COMPLETELY NEW TO PHP San someone supply me with a PHP script to read and write to a text file on the server Also any suggestion on a free PHP editor?
3
by: hunterb | last post by:
I have a file which has no BOM and contains mostly single byte chars. There are numerous double byte chars (Japanese) which appear throughout. I need to take the resulting Unicode and store it in a...
12
by: James Norton-Jones | last post by:
Hi, Am I trying to hold the data of a DataGrid in a label so that when the form is reposted the DataGrid can be repopulated. The problem I am having is that I don't understand how to get the...
10
by: Tibby | last post by:
I need to read/write not only text files, but binary as well. It seems like on binary files, it doesn't right the last 10% of the file. -- Thanks --- Outgoing mail is certified Virus...
2
by: Karen Grube | last post by:
Hi! I hate to bother you all with this, but I don't know how best to approach a particular task. Here's the deal: Once a month I receive in my own inbox on my company's Outlook Exchange...
3
by: sb Luis | last post by:
I Use the following code to read from MS Word, but I couldent read Formated Text (RTF). How Can I read formated text from MS Word Doc without using clipboard. thanks. Word.ApplicationClass...
5
by: VB Programmer | last post by:
I have an HTML file that I want to read on the fly and insert the contents into a string (for the body of an email.) How can I do this?
2
by: catronro | last post by:
I want to read an xml file and build a string based on that file. But when i try to implement it i get an Object Required error. Any help would be greatly appreciated. try { var xmlDoc = new...
5
by: =?Utf-8?B?bXBhaW5l?= | last post by:
Hello, I am completely lost as to why I can't update a DropDownList inside a DetailsView after I perform an insert into an object datasource. I tried to simply it down to the core demostration:...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
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,...

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.