delete folders and files using php??

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

Post Reply
User avatar
PHPycho
Forum Contributor
Posts: 336
Joined: Fri Jan 06, 2006 12:37 pm

delete folders and files using php??

Post by PHPycho »

Hi all of you
my questions>>
*how to delete folders?
*how to delete all files in a folder?
*how to delete certain files for ex. ".php" extension files in a folder?

I would really appreciate your help.
Thanks in advance to all of you.
User avatar
Luke
The Ninja Space Mod
Posts: 6424
Joined: Fri Aug 05, 2005 1:53 pm
Location: Paradise, CA

Post by Luke »

User avatar
PHPycho
Forum Contributor
Posts: 336
Joined: Fri Jan 06, 2006 12:37 pm

Post by PHPycho »

Thanks Mr.The Ninja Space Goat
i got the basic idea...
besides, I found a good recursive function for deleting files and folders...
Hope this will be helpful to many..
the link is below:

http://lixlpixel.org/recursive_function ... ry_delete/[/url]
User avatar
Kieran Huggins
DevNet Master
Posts: 3635
Joined: Wed Dec 06, 2006 4:14 pm
Location: Toronto, Canada
Contact:

Post by Kieran Huggins »

PHPycho wrote:Thanks Mr.The Ninja Space Goat
I just imagined:
The Ninja Space Goat wrote:My father is Mr.The Ninja Space Goat, you can just call me The Ninja Space Goat.
:rofl:

I need sleep :cry:
Post Reply