Hai all, I am doing one project on that i have created the directory for upload the files, I have successfully create the directory using "mkdir" using 700 permission, the problem is i could not remove the directory and i could not remove the file in the particular directory from the server. anyone know what is the solution for this?
"I" is not user account on most linux machines. what user account created the dir, what user account tries to delete the dir? is dir empty or not?
Actually my server is unix server, i am doing the project for university, once the admin enter the values and submit the values, the directory will be create with student name and two pdf file will be create one for mark and another for degree certificate that two pdf file will upload into the corresponding student directory, this is the process, all have been done successfully, but the problem is i could not remove the directory. I could not delete the empty directory too...
I am not using rmdir, there is no process for rm dir, i have deleted manually, but it not been deleted. what can i do...
manually means via ftp or ssh? your dir is created by user "wwwrun" or "apache" or somthing. with 700! then user "joe" or "ssh" or "ftp-joe" wants to delete it. sure this fails! error message is something with "no permission" ?
yes of course i am using apache server. i have try to delete through filezilla, but the error message is Permission denied.
no doubt. ftp-user and apache-php-user are not same. only the user that has created dir can delete it. chmod or chown. if not possible you must delete via apache-php. can use scripts like phpfilemanager from sourceforge.
epxlain what? *nix file permissions? check wiki for this. download phpfilemanager. upload to you docroot. delete folder. still can not understand why no rmdir in unix? other command to execute in php to remove a directory? exec("rmdir folder") no work? rmdir("folder") not work? if rmdir really not possible you must create file with 777
evrybody on unix has a userid. there are user ids that are used for certain application. normally the ftp-user has a user id that is different from the user id of apache. if php is run as apache module, files are created with the id of apache. if php is run as cgi the user id is different. most times it is same user id as ftp-user account uses.