PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
goblinhybrid
Forum Newbie
Posts: 8 Joined: Tue Dec 09, 2003 2:41 pm
Post
by goblinhybrid » Tue Dec 09, 2003 4:45 pm
if a file doesn't exist will fopen() create one by default? if not, how do i check if a file exists and create a new one??
qads
DevNet Resident
Posts: 1199 Joined: Tue Apr 23, 2002 10:02 am
Location: Brisbane
Post
by qads » Tue Dec 09, 2003 5:22 pm
yep, fopen will make a file if there ist one already, to see if a file exists you can use [php_man]file_exists[/php_man].
goblinhybrid
Forum Newbie
Posts: 8 Joined: Tue Dec 09, 2003 2:41 pm
Post
by goblinhybrid » Wed Dec 10, 2003 10:38 am
thanks
is there a way to make a new file on its own?
also, is there a way to create a directory?
qads
DevNet Resident
Posts: 1199 Joined: Tue Apr 23, 2002 10:02 am
Location: Brisbane
Post
by qads » Wed Dec 10, 2003 11:56 am
[google]file manipulation with php[/google]
[google]dir manipulation with php[/google]
above has tutorials on both subjects.
enjoy.