- file_get_contents: documentation ( source)
- print_r: documentation ( source)
- preg_match_all: documentation ( source)
<?php
$url = 'http://www.6dollarshirts.com/home.php';
$fp = file_get_contents($url);
///<a href="product.php?productid=12177"><img src="http://6dollar.threadpitinc.netdna-cdn.com/images/T/Merica_T_SHIRT_tn.jpg"
preg_match_all('/productid=(.*?)"><img src="(.*?)\.jpg/', $fp, $matches);
print_r($matches);
?>