changing file contents using open function.

Forum closed. All further discussion to be discussed at https://github.com/OpenKore/

Moderator: Moderators

Message
Author
sli
Perl Monk
Perl Monk
Posts: 811
Joined: 04 Apr 2008, 17:26
Noob?: No

Re: changing file contents using open function.

#11 Post by sli »

No no, everyone always second guesses my answers, even then obviously correct ones.
cs : ee : realist

iamanoob
Plain Yogurt
Plain Yogurt
Posts: 82
Joined: 04 Apr 2008, 09:49

Re: changing file contents using open function.

#12 Post by iamanoob »

bin12 wrote:^
what im trying to say is that you didnt get my point. im sorry if your that sensitive. :lol:


ouch, deep inside...
it really does... XD
Image
DARKest Ninja

sli
Perl Monk
Perl Monk
Posts: 811
Joined: 04 Apr 2008, 17:26
Noob?: No

Re: changing file contents using open function.

#13 Post by sli »

bin12 wrote:^
nobody tells you're a noob, what im trying to say is that you didnt get my point. im sorry if your that sensitive. :lol:

Then you didn't explain it well enough. I gathered that you want to open a file, clear the contents of that file, and write to it. That's what I showed you how to do. Unless you want to completely remove and rewrite the file, then you'd use this:

Code: Select all

unlink($file);
open(FILE,">","$file");
cs : ee : realist

Locked