hi i want to make a script with regex i need to cath all gif images urls with php . here is what i did
<?php
$subject = file_get_contents("http://www.9gag.com");
$search="^https?://(?:[a-z\-]+\.)+[a-z]{2,6}(?:/[^/#?]+)+\.(?:jpg|gif|png)$";
preg_match($search, $subject, $result);
print_r($result);
?>
my example is not working . i just searched stackoverflow.com read some examples but not enough i think thanks
- i need to catch gif images with url's
- i need this built with php and regex