View Single Post
Old 03-11-2006, 08:33 PM  
BigBen
Confirmed User
 
Join Date: Nov 2004
Location: scv
Posts: 2,299
Thanks for the help. What can I use to match just the image name from the string extracted from the first match?

Ie. How do I match just pic.jpg out of: src="http://example.com/images/pic.jpg"

I tried: preg_match("/\/.+?\.jpg/", $matches[1], $imagematch);
but that matches the longest string possible (//example.com/images/pic.jpg)

Thanks.
BigBen is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote