Change register_globals? - Printable Version +- ispCP - Board - Support (http://www.isp-control.net/forum) +-- Forum: ispCP Omega Development Area (/forum-1.html) +--- Forum: General discussion (/forum-11.html) +--- Thread: Change register_globals? (/thread-665.html) Pages: 1 2 |
Change register_globals? - Eminos - 05-24-2007 09:34 PM Hi there, I need to set register_globals to ON for some scripts. On Debian Sarge (my old server) I could just put an .htaccess file with php_flag register_globals On in that directory where I had that script. But this doesn't work anymore (is it any difference now because I run php5 with fcgi?) I tried adding the line register_globals On in both the domain specific php.ini and the "global" in etc/php5/cgi/php.ini. No change. Stil shows up as "Off". Of course I restarted apache2 between changes /E RE: Change register_globals? - SunDanCe - 05-24-2007 09:38 PM Eminos Wrote:Hi there, take a look in /var/www/fcgi/domain.tld/php5/php.ini in that file you can change php values only for that domain, if you want to do it for everyone (i do not recommed it) just edit /var/www/fcgi/master/... Best Regards RE: Change register_globals? - Eminos - 05-24-2007 09:42 PM As I said, I've already tried that. But in that domain specific php.ini there IS NO register_globals string, so I added it, but still no luck. /E RE: Change register_globals? - BeNe - 05-24-2007 09:57 PM Yeah, i also started to test override the php setting with a .htaccess and i always get an Internal Error 500 ! I tested this one: Code: # RE: Change register_globals? - Eminos - 05-24-2007 10:04 PM I get error 500 with that in the htaccess file. Error log: /var/www/virtual/domain.net/htdocs/whmcs/.htaccess: <Directory not allowed here Actually I don't get the 500 error when just having the php_flag register_globals On in the htaccess, It's just that it doesn't "adapt", my script still shows as register_globals Off. /E RE: Change register_globals? - Eminos - 05-24-2007 10:11 PM Ok, I found part of the problem. It was the php4 php.ini I had to edit !! .. Even tho I use php5 (hack from FAQ section). But still. I want to use htacess file in just that directory, instead of the domain specific php.ini. /E RE: Change register_globals? - joximu - 05-25-2007 04:18 AM php settings in .htaccess file or direct in the apache conf (see post from BeNe) don't work with phpfcgi. Since php is fully separated from the rest of apache. The only thing you can do is creating different fastcgi prozesses (starters) and put the thin in the respective php.ini... RE: Change register_globals? - Eminos - 05-25-2007 04:24 AM Oh, ok, then I know, thanks So .. what is the advantage of running php via fcgi ? Is it JUST that we can choose betwen php4 and php5, or is it something else ? /E RE: Change register_globals? - joximu - 05-25-2007 04:42 AM It's the fact that the php scripts will run with the ownership and permissions of the vuXXXX user (with mod_php all php were running as apache user and when uploading files with ftp and then changing theese files with php you always have problems (or you chmod to 777 which is not good either). So, it's security. You even could disable openbase_dir - the user vu2001 cannot see the php files from vu2002 and therefore it should be possible to protect the config files better... This is a big thing for ISP with moe than a cuple of foreign customers... It's maybe easier with mod_php - and if it's only you on the machine and maybe you friends then there is no reason why not to go back to mod-php. And, there is another thing: Since mod-php cannot be used in the mpm-worker of apache you loose some performing advantages of threads which were available since apache2 but not usable because of mod-php... hope that's it... RE: Change register_globals? - Eminos - 05-25-2007 04:46 AM You're the man joximu ! Maybe you wanna develop the mpm-worker thing? I know there is mpm-worker and threaded, but what is it actually ? /E - *like to learn* ^^ |