PHP string help
Posted: Wed Oct 29, 2003 12:49 pm
Ok, I am calling a perl script and getting the output back and storing that in a variable. Here is what the sample output looks like:
210: X.500 Directory 210: Tier 2 Dialup 210: Mail (blah blah blah) 210: TimeManager (blah blah blah) 510: Something else
210 means success and 510 means failiure.
I basically want to separate out each and display it this way:
X.500 Directory Success
Tier 2 Dialup Success
Mail Success
TimeManager Success
Something else Failiure
There could be any number of these in a variable. Is there anyway of doing this without searching for each separate possibility?
Basically search for a code with a colon following it, and then take the string after it, until the next colon or something?
-Thanks
210: X.500 Directory 210: Tier 2 Dialup 210: Mail (blah blah blah) 210: TimeManager (blah blah blah) 510: Something else
210 means success and 510 means failiure.
I basically want to separate out each and display it this way:
X.500 Directory Success
Tier 2 Dialup Success
Mail Success
TimeManager Success
Something else Failiure
There could be any number of these in a variable. Is there anyway of doing this without searching for each separate possibility?
Basically search for a code with a colon following it, and then take the string after it, until the next colon or something?
-Thanks