Ci sono parecchi errori, ad esempio nella fgets().
Prova questo
Codice PHP:
<?php 
function convertIntoTab($filename,$seperator,$lineseperator) {
    
$row=1;$count=0;

    if ((
$handle fopen($filename"r")) !== FALSE) {
        while ((
$data fgets($handle)) !== FALSE) {
                echo 
"<table>\n";                
                
$str=explode($seperator,$data);
                foreach(
$str as $k => $str1) {
                    if (
$k <> 0) {
                        echo 
"<tr>\n";
                        echo 
"<td>\n".$str1."\n</td>\n"
                        echo 
"</tr>\n"
                    }
                }
                echo 
"</table>\n";    
        }
        
fclose($handle);
    }
}
print 
convertIntoTab('test.txt',"#","+");

?>