Ok, now I got it.
I already knew that the newline is coded differently in Unix/Win/Mac. But I
did not know, that in PHP on Win32 "\n" is 0D 0A when outputed, but 0A
otherwise. Confusing...
Hannes
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For a
on my linux based system
echo ord("\n");
is 10 which is 0A in hex. windows machings usually consider newline to be 0A0D or 0D0A
mac's usually are 0D I would convert your file. I have to do this often with file
uploads.
// convert all 0A0D and 0D0A to 0A0A
$data = str_replace(chr(13), chr(10)
Hi!
$astrData = file($astrCounterFile[$i]);
echo "|\n|";
echo "|" . $astrData[0] . "|";
echo "|" . $astrData[1] . "|";
//$astrData[1] = "\n";
//echo "|" . $astrData[1] . "|";
echo "|" . $astrData[2] . "|";
for($k = 0; strcmp($astrData[$k] , "\n") && ($k < 50); $k++)
// for($k = 0; ($astrData[$
3 matches
Mail list logo