coppermine-gallery.com/forum

Support => Older/other versions => cpg1.1.X Support (standalone) => Topic started by: wormie_dk on September 29, 2003, 05:26:17 PM

Title: How to configure safemode to avoid sillysafemode?
Post by: wormie_dk on September 29, 2003, 05:26:17 PM
My provider has just changed their safemode config and now I am restricted to "silly safemode". What should be changed so that I avoid it? Phpinfo can be seen here: http://alberg.dk/phpinfo.php

Thanks  :D
Title: How to configure safemode to avoid sillysafemode?
Post by: Zarsky on September 29, 2003, 05:31:34 PM
WTH is "silly safemode"?  This a new one on me?  I googled and found no reference to that.  Are you talking about regular plain old normal "safemode"?  I see nothing in your phpinfo that suggests a level of safemode above normal safemode.
Title: How to configure safemode to avoid sillysafemode?
Post by: wormie_dk on September 29, 2003, 07:50:38 PM
Quote from: "zarsky99"WTH is "silly safemode"?  This a new one on me?  I googled and found no reference to that.  Are you talking about regular plain old normal "safemode"?  I see nothing in your phpinfo that suggests a level of safemode above normal safemode.
It is something coppermine defines when this test failes:
function test_silly_safe_mode()
{
        $test_file = 'dummy/dummy.txt';
        mkdir(dirname($test_file), 0755);
        $fd = @fopen($test_file, 'w');
        if (!$fd) {
            rmdir(dirname($test_file));
                return true;
        }
        fclose($fd);
        unlink($test_file);
        rmdir(dirname($test_file));
}
It means that coppermine cannot write to a directory that it has created itself. Which again means that all pictures from all users are placed in userpics instead of userpics/10001 userpics/10002 userpics/10003 and so forth.

My hold host had this http://alberg.dk/phpinf.htm php setup and coppermine worked without silly safe mode there...
Title: How to configure safemode to avoid sillysafemode?
Post by: Joachim Müller on September 29, 2003, 10:34:43 PM
there's a reason why Greg named this "silly_safe_mode": some webhosts choose to run save_mode to restrict their users from doing certain things on the server; but usually they're only just lazy. Silly safe mode settings are only necessary if safe_mode isn't configured properly by your webhost. Try to contact them and ask them what can be done about this (but don't tell them I said their server was improperly set up :wink: ). I'd personally only choose a webhost with safe_mode if I were on a very low budget, so maybe you'll want to consider choosing another webhost.

GauGau
Title: How to configure safemode to avoid sillysafemode?
Post by: wormie_dk on September 29, 2003, 10:43:02 PM
Quote from: "gaugau"I'd personally only choose a webhost with safe_mode if I were on a very low budget, so maybe you'll want to consider choosing another webhost.

When I signed up they didn't use safemode  :(
Title: How to configure safemode to avoid sillysafemode?
Post by: Knight on October 18, 2003, 06:33:32 PM
I found a silly way to be able to upload pictures to /userpics/10001..  etc..
At least it worked for me.
My webhost is running in safe_mode  but for some reason coppermine didn't run in silly_safe_mode, maybe it had something to do with the integration, i really dunno.

Solution:
Modify db_input.php

Make an ftp connection, log in
create the dir, chmod it to 777
close connection
upload file
Make an ftp connection, log in
chmod the dir to 755
close connection

or something like that.
It's working on my site...
It solved the unable to move problem since that way i am the owner of the dir.

Check it out if you want ;)
my patched file ;)
http://filer.staroffice.com/view/Knight/WWW/db_input.zip

You have to modify :
$username='your ftp username';
$password='yout ftp password';
$plugin_dir='coppermine_dir';

This worked in coppermine version 1.1.1 devel integrated into e107 (http://www.e107.org) by Mcfly