Oh ok i see now..
well i ran the code...
<?php
$contents = file_get_contents('somefile.html');
$start = strpos('<body>', $contents);
$end = strpos('</body>', $contents, $start);
$contents = substr($contents, $start, $end-$start);
?>
and it worked just fine..
so then i did this...
<?php
$contents = '';
$start = strpos('<body>', $contents);
$end = strpos('</body>', $contents, $start);
$contents = substr($contents, $start, $end-$start);
?>
and it returned
Warning: strpos() [function.strpos]: Empty delimiter. in V:\Core\htdocs\test.php on line 3
Warning: strpos() [function.strpos]: Empty delimiter. in V:\Core\htdocs\test.php on line 4
ok so this means the html file your opening is empty.