I have text files, with thousand of lines, and I want to make a php page where I can see them, and that it opens in the exact line where I want. I mean, the scrollbar must be in the line I want. The file is full open on a pre Tag, but the scroll bar must be in the line 'N'.
This the php to open the file:
echo "<pre >";
$file = $pathOfFile;
$contents = file_get_contents($file);
$lines = explode("<br>", $contents); // this is your array of words
foreach($lines as $word)
echo $word;
echo"</pre>";