From:             [EMAIL PROTECTED]
Operating system: Win2K
PHP version:      4.1.1
PHP Bug Type:     Filesystem function related
Bug description:  fopen() when using r+ overwrites whateva is at top

<?
$output = "\nGday.\n";
$directory = dirname($path_translated);
$filename = fopen($directory . "members/addop.txt", "r+", 1) or die("Can't
open file");
if ($output) { 
$written = fwrite($filename, $output) or die ("Couldn't write to file");
}
fclose($filename);
?>

When usin r+ it writes to the file addop.txt but just overwrites whateva
is at the top. i want it to just add to the top of the file. 
-- 
Edit bug report at http://bugs.php.net/?id=15553&edit=1
-- 
Fixed in CVS:        http://bugs.php.net/fix.php?id=15553&r=fixedcvs
Fixed in release:    http://bugs.php.net/fix.php?id=15553&r=alreadyfixed
Need backtrace:      http://bugs.php.net/fix.php?id=15553&r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=15553&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=15553&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=15553&r=notwrong
Not enough info:     http://bugs.php.net/fix.php?id=15553&r=notenoughinfo
Submitted twice:     http://bugs.php.net/fix.php?id=15553&r=submittedtwice

Reply via email to