explode problems...

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Todd_Z
Forum Regular
Posts: 708
Joined: Thu Nov 25, 2004 9:53 pm
Location: U Michigan

explode problems...

Post by Todd_Z »

If I have a line such as "<img src='pic.jpg' alt='pic'>" then i explode it around the "<", then i get two parts, is there a way to only give me the right of the < if there is nothing to the left?
McGruff
DevNet Master
Posts: 2893
Joined: Thu Jan 30, 2003 8:26 pm
Location: Glasgow, Scotland

Post by McGruff »

I'm not sure exactly what your need is here but it sounds like regex might be the answer.
Post Reply