note 74812 rejected from function.fwrite by tularis

From: Date: Sat, 28 Apr 2007 08:42:21 +0000
Subject: note 74812 rejected from function.fwrite by tularis
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-125946@lists.php.net to get a copy of this message
Note Submitter: blasta at neostrada dot pl ---- Hi, I've found weird behaviour in fwrite I was trying to do : <?php $myString = 'My simple text /n/n Second simple text'; fwrite($fh,$myString); ?> And what happened ? In output file instead of line endings /n/n was written. OUTPUT : My simple text /n/n Second simple text After changing ' to " it worked so watch out. <?php $myString = "My simple text /n/n Second simple text"; fwrite($fh,$myString); ?> OUTPUT : My simple text Second simple text

« previous php.notes (#125946) next »