. Visit BoxedArt.com



Home | Link Us | Contact Us | Advertise



Big Resources
1-Click-Clipart
123Webmaster
A1Javascripts
Boxed Art
Font Files
FreeWare Files
FreeWebTemplates
Fresher Image
HTML Forums
Perl Access



 


Perlaccess : Tutorials : File and Directory
Deleting Directories (12.6)
by Jacob A. Wheeler
http://www.bigresources.com

Deleting Directories:

rmdir (DIRECTORY)
DIRECTORY = Full path to the directory you want removed

Example:
#!/usr/bin/perl
$dir = "/path/to/new"
deleteDir();
sub deleteDir {
rmdir($dir) or "Error deleting directory ($dir)\n";
exit();
}
Take note that the dir you are trying to remove must be empty! Otherwise an error will be produced.



Mascot team created by Drawshop.com