How to seach the whole website?

this is a code that gets the link of the video from a website of one page

<?php
$html = file_get_contents('http://test.com/movie.php?id=7333');
if (preg_match('/<param name="movie".*/', $html, $matches)) {
  echo "1- Match was found <br />";
  echo $matches[0];
}
?>

i would like to make it search such contents from the whole website test.com not just test.com/movie.php?id=7333
any idea how to do that???

Not easy using the method that youve got there, youd have to loop through each page of the site checking for a match.

Searches are usually carried out when the content is held in a database, thats a much better and easier method.