OK I have a php script that goes out and grabs data from an amazon xml feed. Easy enough.. But I only want the first image it returns. Right now it returns up to 10. Here's an example of the data it returns: How would you grab just the first image?
You can use xml functions or regex for doing that. Regex example: if (preg_match('/<image[^>]*><\/image>/si',$s,$m)) echo $m[0]; PHP: there $s contains your xml.