aruns Posted February 4, 2009 Share Posted February 4, 2009 Hello Guys, This function was i am using to dynamic delete folder but it says Warning: rmdir(xxxxxxxxx) [function.rmdir]: Permission denied in ############## on line 96.... Help me i am worry about that.... function delete_folder($ftp_path){ if(is_dir($ftp_path)){ $folder_files = get_all_contents($ftp_path); for($i=0; $i<=count($folder_files); $i++){ if(is_file($folder_files[$i])){ unlink($folder_files[$i]); }elseif(is_dir($folder_files[$i])){ delete_folder($ftp_path . $folder_files[$i]); } chmod($ftp_path, 0777); return rmdir($ftp_path); } } } Link to comment https://forums.phpfreaks.com/topic/143744-problem-in-folder-delete/ Share on other sites More sharing options...
trq Posted February 4, 2009 Share Posted February 4, 2009 Its quite simple. Apache does not have sufficient permission to remove the directory in question. Link to comment https://forums.phpfreaks.com/topic/143744-problem-in-folder-delete/#findComment-754189 Share on other sites More sharing options...
aruns Posted February 4, 2009 Author Share Posted February 4, 2009 Thank you for the replay... If any options to delete folder.... Link to comment https://forums.phpfreaks.com/topic/143744-problem-in-folder-delete/#findComment-754191 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.