Please give more information. Hope you dont mind.

General discussions related to php

Moderators: macek, egami, gesf

vikaspa
New php-forum User
New php-forum User
Posts: 21
Joined: Wed Jun 19, 2002 10:03 pm

Please give more information. Hope you dont mind.

Postby vikaspa » Wed Sep 18, 2002 12:28 am

Dear Mr.Jay,
Yourresposne was most informative

However How do I read this file ?
Once i could rea dthis file, the delimiting can be managed.

I really dont know how to read outlook express file can be read ...

With regards
Vikas AThavale

Your repspose

"OE stores the emails in mbx files, so you'll have to search for them (they're all in one folder, dependant on your OS). Anyway, you will have to read the file and delimit each email. Then you'll have to run a regular expression to sift out all the emails. Once you've got them, you can do as you wish with them!"

Jay

Postby Jay » Wed Sep 18, 2002 1:20 am

No offence but you can start by reading the manual, I'm here to help you out, not write your code for you!

Anyways, you'll have to use one of the filesystem functions to read the file (file()) and then loop through each line. Read the mbx first and see if you can figure out the pattern to the end of the emails. But then again since you want to extract email address, this isn't a problem. Just use a regular expression on small chunks of text at a time (use a while loop to break the whole mbx into smaller chunks) and then add each email addy into an array. Then extract all the distinct ones from the array!


Return to “PHP General”

Who is online

Users browsing this forum: No registered users and 1 guest