coppermine-gallery.com/forum

Support => cpg1.3.x Support => Older/other versions => cpg1.3 Installation & Setup => Topic started by: Jet on September 17, 2004, 09:57:27 PM

Title: config.php - cannot save options
Post by: Jet on September 17, 2004, 09:57:27 PM
My Problem:
When I change something in the Config (f.e. e-mail, style, lang...) and press the "Save"-Button, then comes "Not found" - Error.
The browser is searching for "http://po0301.playz.ru/po/gallery/config.php", while the program is in "http://po0301.playz.ru/gallery/config.php".
What must i do?
Some info about my hosting:
as you can see, I created subdomain called "po0301", and it works like that:
when I upload my site via FTP, I'm actually uploading files to "/html/po/" directory.
So, subdir "po" means root of the subdomain "po0301".
("po0301.playz.ru" and "playz.ru/po/board/" has the same result).

How can I fix it?
Title: Re: config.php - cannot save options
Post by: Joachim Müller on September 17, 2004, 10:10:00 PM
I can't see any difference between the urls you posted, but this behaviour is known and based on server-misconfig. Your server var $PHP_SELF isn't configured properly. Although you could edit the <form> tag in config.php to point to "config.php" as action instead of $PHP_SELF, I rather recommend looking into the server config instead. Am I right in assuming you're running your own server?

Joachim
Title: Re: config.php - cannot save options
Post by: Jet on September 17, 2004, 10:18:05 PM
I think that if I change <form> tag in config.php, this error will also occur somewhere else, right?
No, I'm not running my own server, that's why I wonder if it would be so easy :) Of course I'll call support...
But can I check this value manually?
Title: Re: config.php - cannot save options
Post by: Joachim Müller on September 17, 2004, 10:58:06 PM
go to admin tools, choose phpinfo, then search the code for $PHP_SELF. You're right with your guess: if you manually fix the form action for config.php, it will solve your issues with saving the config settings, but you will run into similar problems on other pages, as $PHP_SELF is being used on various pages (in various files).

Joachim
Title: Re: config.php - cannot save options
Post by: Jet on September 18, 2004, 04:39:13 PM
hm... looks like my hoster just cannot resolve this small trouble...
that's what I discovered:
$PHP_SELF is always initialized in includes\init.inc.php
if I change
$PHP_SELF = isset($HTTP_SERVER_VARS['REDIRECT_URL']) ? $HTTP_SERVER_VARS['REDIRECT_URL'] : $HTTP_SERVER_VARS['SCRIPT_NAME'];
with
$PHP_SELF = $HTTP_SERVER_VARS['REDIRECT_URL'];
then everything seems to be alright(!), BUT!
"Notice: Undefined index: REDIRECT_URL in /www/vhosts/playz.ru/html/po/gallery/include/init.inc.php on line 172" - now appears on every page... what does it mean? debug is off, notices are also off, can I just get rid of this message and work on (and how?)?

Just for info: you can visit http://po0301.playz.ru/gallery/ to see what's happening...
Thanks...
Title: Re: config.php - cannot save options
Post by: Jet on September 18, 2004, 09:05:59 PM
OK, I decided to manually fix some files, this would work pretty fine...
Just a little suggestion: when I installed phpBB2, I faced the same problem, but in phpBB2 this problem can be solved very easy - altering of the path variable in settings quite enough. It would be very nice, if you will do something like this in future versions...