Reply to Re: Get all the email addresses from a text file

Your name:

Reply:


Posted by Geoff Berrow on 03/22/06 20:35

Message-ID: <44217e7e$0$471$626a54ce@news.free.fr> from Nico contained
the following:

>
>I have a .txt file with a lot of text mixed with some email addresses. I
>would like to get all the email addresses in a $mails[] variable. Does
>anyone know how to do this in php.

Yes
>
>Thanks a lot for your help,

You're welcome. :-)

Oh, you'd like to know ?

Use implode() to get all the words in the text into an array. Then loop
through the array checking each word with strpos() to see if it contains
an @symbol. If it does, assign it to a new array. The new array will
contain everything with a @ symbol, probably mostly email addresses.

--
Geoff Berrow 0110001001101100010000000110
001101101011011001000110111101100111001011
100110001101101111001011100111010101101011

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация