![]() |
| Domain Name Sales | Domain Software | Calculate UK Domain Drop Dates | Domain Registration | NameDrive | Domain Parking | Subscribe to our Domains For Sale newsletter |
| | ||||||
| Home | Register | Rules | Membership Upgrade | Domains For Sale | Domain Name Escrow | Mark Forums Read | Domain Classified | Chat Room |
| Scripts and Coding PHP, MySQL, scripts |
![]() |
| | LinkBack | Thread Tools | Display Modes |
| | #1 (permalink) |
| Administrator |
This is a simple PHP SCRIPT which allows the user to extract emails ids from any form of text.This proves really useful when we have a bundle of email ids in a raw format and just want to get into into a database in an orderly fashion. <?php //Function to extract the email IDS function extract_emails($text_content){ //Matching the content of the content file against the email id format preg_match_all(“/[\._a-zA-Z0-9-]+@[\._a-zA-Z0-9-]+/i”, $text_content, $match_email); return $ match_email [0]; } //Getting the content of the test file $text = file_get_contents(“content.txt”);”; //Calling the function to extract the email ids $emails = extract_emails($text); //Displaying the email ids in individuals lines print(implode(“\n”, $emails)); ?> |
| |
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Domain Name Community | Replies | Last Post |
| Domain and Website Auction Script - *7 Day FREE Trial* | jordanb27 | Scripts and Coding | 1 | 04-02-2009 04:21:36 PM |
| Cpanel Advice: Please Read! SPAM IN YOUR EMAILS! | Billy | Hosting | 3 | 27-07-2008 12:32:27 PM |