It could be that a php error is occurring on the page.
add the following code at line 1 to turn on error reporting:
<?php
error_reporting(E_ALL);
ini_set('display_errors','on');
?>
post back any error that occur on testing and a copy of your page so I can take a look at the code.