Figured it out:

I just rewrote the first 3 lines with a few new Line Characters and place
respat the
Line I wanted Changed with its Variable...

fputs($file, "<?\nline1\nline2....etc");

The reason I was trying to read it at first was that I had a Cookie Set at
the very
top and I thought it would reset this each time it rewrites it...  Since my
code is
running on Sessions that doesn't really matter...  However just for
Interests Sake...

Given that I was not using sessions, and I wanted the Cookie Maintained,
would
rewriting it to self file on each try, reset the cookie hence elongating the
Cookie
expiration Time?

Spike...

"Kondwani Spike Mkandawire" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I am trying to read and write to a file on Line 5 and line 5 alone...
> $file = fopen($fileName, "r+");
> Places the pointer at the beginning of the file I have tried the
> following...
>
>     $line = fgets($file, 255);
>    $line = fgets($file, 255);
>    $line = fgets($file, 255);
>    $line = fgets($file, 255);
>    fputs($file, "the Line I want to write;");
> but nothing is happening...  Please Help...
>
> Kondwani
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to