breaking a text file into paragraphs based on strings


Posted on 16th Feb 2014 07:03 pm by admin

I have a text file of email addresses that is all squished together. It looks like this:

abcd@gmail.comfefef@mail.comfefefef@yahoo.comfewferf@mail.net...

What I want to do is insert a paragraph after every instance of "com" or "net" etc so I can read it as a list like this:

abcd@gmail.com
fefef@mail.com
fefefef@yahoo.com
fewferf@mail.net


thank

No comments posted yet

Your Answer:

Login to answer
56 Like 28 Dislike
Previous forums Next forums
Other forums

Generate multilayered array from string.
ok so i have a string that looks like this:
Code: [Select]blog:edit_all,delete_all|users:edit_all

MS are the best!!!
Visit http://www.microsoft.com/australia/windows/default.aspx?h=watch-a-demo and click the massive '

PECL uploadprogress for php5.2
Hey, I just installed PHP5 via .htaccess on my 1and1 Shared Hosting Account.

How would I exac

Image resize
Hi again fellers

I managed to sort out the issues with the folder,

Final hurdle is th

How to display value in drop down list after form has been reloaded
Please bear with me as I am very new to php and html.

I have a form with several drop down me

I need help with formatting date from mysql! with php!
Hello guys

*Note: this is a php question not MySQL question, please do not move it to mysql s

Passing Arguments to execlp()
I'm writing a program that mimics a unix shell. It's supposed to take commands with arguments and ex

License Issue - service type user
Hi,

I would like to understand the following issue regarding sap license.
I wish to

dropdown menu
Hello everbody,

I am php newbie.
I need to develop a program that once click the drop do

Sessions Value Not Saved
Hi,

Im making a login form and im using this code:
Code: if($login=="true"){

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash