for ($i = 0; $i < $totalLinesinFile ; $i++) {
echo "Line number is ".$i."<br>";
echo wholeTextFile[$i]."<hr>";
}