1
nuker
can't delete xoopsgallery folder
  • 2004/4/29 13:44

  • nuker

  • Not too shy to talk

  • Posts: 129

  • Since: 2002/12/14


i'm deleting files off my web hosting space. when i try to delete the xoopsgallery folder, i cannot delete the cache folder.

i get the following message from cute ftp:

Requested action not taken (e.g., file or directory not found, no access).

how can i fix this?

2
jurgis
Re: can't delete xoopsgallery folder
  • 2004/4/29 14:32

  • jurgis

  • Just popping in

  • Posts: 72

  • Since: 2003/3/20


because when installing You set it to be owned by wwwdata or similar ..
so a solution would be to write some php script for deleting the dirs and run it via browser (as wwwdata user) ;)

3
Dr3vil
Re: can't delete xoopsgallery folder
  • 2004/4/29 15:00

  • Dr3vil

  • Friend of XOOPS

  • Posts: 57

  • Since: 2003/5/10


Here is a copy of the cleanup.php code I used from the Gallery website. Works like a charm....

<font size=+2>
Gallery Cleanup Script
font>
<
p>
Because Gallery runs as part of the webserverany files it creates
are owned by the webserver process
.  If you want to modify those
files yourself
you need to get the webserver to change the permissions
on them so that you have access
.  That's what this script is for.
Simply enter the path to your albums directory below and this script
will make every file in that path (that it can access) writable
by everybody.  Then, you can do whatever you want to the files.




Path (on your filesystem) to a file or directory to fix?


(examples: /home/~you/public_html/albums, /usr/www/htdocs/albums)








if ($dir) {
    echo "


";
    fix($dir);
}

function fix($obj) {
    if (is_dir($obj)) {
        status("Directory: ", $obj);
        if ($fd = opendir($obj)) {
            while (($child = readdir($fd)) != false) {
                if (!strcmp($child, ".")) {
                    continue;
                }

                if (!strcmp($child, "..")) {
                    continue;
                }

                $fullpath = "$obj/$child";
                fix($fullpath);
            }
            chmod($obj, 0777);
        } else {
            error("Error reading dir", $obj);
        }
    } else if (is_file($obj)) {
        print "File: $obj
";
        chmod($obj, 0666);
    }
}

function status($msg, $obj) {
    print "$msg: $obj
";
}

function error($msg, $obj) {
    print "$msg: $obj
";
}

?>

Login

Who's Online

195 user(s) are online (131 user(s) are browsing Support Forums)


Members: 0


Guests: 195


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits