There must be some delimiter right?
ie.
12312121313\n
asdhflahdfjlashlfkjasjfhaslkjfhlasf
ie.
1245645634\n\r
oyoteryoitweutitiueriuoitu
ie.
<text>1231241266788</text>\n
xzbvmnzbmvnbzxmnbvmnzxv
There must be some delimiter, either "\n", "\r", "\r\n", "\n\r", "</" etc, etc.
If there is NO way to tell when the number stops and the data starts then your dealing with a file of fully random junk, if so you may as well guess at the sze, cause you wont find it.
If the number stops after the first "\n" then easy.
$data = fread($fp, filesize($fp));
$tempdata = explode("\n", $data);
$num = $tmpdata[0];
$data = ereg_replace($tmpdata[0], $data);
right?
Chris Lee