By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
458,104 Members | 1,590 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 458,104 IT Pros & Developers. It's quick & easy.

Turn off Register Globals gives me a headache

P: n/a
Hi...
It drives me nuts this server.
My php.ini says that register_globals is OFF and when I run phpinfo() it
says they are ON.

I restarted both httpd and the whole server still nothing.
IS there any other place that my php environment is set ?
It is a dedicated server.. so no shared environment.

If you had that before and you know the answer I'll be happy to listen/read

Thanks
Angelos.
Mar 1 '06 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Angelos Devletoglou wrote:
Hi...
It drives me nuts this server.
My php.ini says that register_globals is OFF and when I run phpinfo() it
says they are ON.

I restarted both httpd and the whole server still nothing.
IS there any other place that my php environment is set ?
It is a dedicated server.. so no shared environment.

If you had that before and you know the answer I'll be happy to listen/read

Thanks
Angelos.


It can also be overridden in the httpd.conf file or a .htaccess file.

But this isn't done very often - and you'd have to add them yourself.

Rather, I suspect either you have an error in your php.ini file - or,
more likely, you're not using the php.ini file you think you are.

Which one does phpinfo() say you're using?

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================
Mar 1 '06 #2

P: n/a
Which one does phpinfo() say you're using?

This is what I am getting from phpinfo()
Configuration File (php.ini) Path /etc/php.ini
Scan this dir for additional .ini files /etc/php.d
additional .ini files parsed /etc/php.d/cce.ini, /etc/php.d/gd.ini,
/etc/php.d/i18n.ini, /etc/php.d/imap.ini, /etc/php.d/mbstring.ini,
/etc/php.d/mysql.ini
..
..
..
register_globals On On
..
..
..

I edit the /etc/php.ini
and here is a part of it with register_globals

..
..
..

; You should do your best to write your scripts so that they do not
require
; register_globals to be on; Using form variables as globals can easily
lead
; to possible security problems, if the code is not very well thought
of.
register_globals = Off

; This directive tells PHP whether to declare the argv&argc variables (that
; would contain the GET information). If you don't use these variables,
you
; should turn it off for increased performance.
register_argc_argv = On
..
..
..

Mar 1 '06 #3

P: n/a
Angelos Devletoglou wrote:
Which one does phpinfo() say you're using?

This is what I am getting from phpinfo()
Configuration File (php.ini) Path /etc/php.ini
Scan this dir for additional .ini files /etc/php.d
additional .ini files parsed /etc/php.d/cce.ini, /etc/php.d/gd.ini,
/etc/php.d/i18n.ini, /etc/php.d/imap.ini, /etc/php.d/mbstring.ini,
/etc/php.d/mysql.ini
.
.
.
register_globals On On
.
.
.

I edit the /etc/php.ini
and here is a part of it with register_globals

.
.
.

; You should do your best to write your scripts so that they do not require
; register_globals to be on; Using form variables as globals can easily
lead
; to possible security problems, if the code is not very well thought of.
register_globals = Off

; This directive tells PHP whether to declare the argv&argc variables (that
; would contain the GET information). If you don't use these variables,
you
; should turn it off for increased performance.
register_argc_argv = On
.
.
.


OK, what about all the additional .ini files which are being parsed?
Which one of those has register_globals set to on?
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================
Mar 1 '06 #4

P: n/a
Jerry Stuckle wrote:
Angelos Devletoglou wrote:
Which one does phpinfo() say you're using?

This is what I am getting from phpinfo()
Configuration File (php.ini) Path /etc/php.ini
Scan this dir for additional .ini files /etc/php.d
additional .ini files parsed /etc/php.d/cce.ini,
/etc/php.d/gd.ini, /etc/php.d/i18n.ini, /etc/php.d/imap.ini,
/etc/php.d/mbstring.ini, /etc/php.d/mysql.ini
.
.
.
register_globals On On
.
.
.

I edit the /etc/php.ini
and here is a part of it with register_globals

.
.
.

; You should do your best to write your scripts so that they do not
require
; register_globals to be on; Using form variables as globals can
easily lead
; to possible security problems, if the code is not very well thought of.
register_globals = Off

; This directive tells PHP whether to declare the argv&argc variables
(that
; would contain the GET information). If you don't use these
variables, you
; should turn it off for increased performance.
register_argc_argv = On
.
.
.


OK, what about all the additional .ini files which are being parsed?
Which one of those has register_globals set to on?


The answer is /etc/php.d/cce.ini
:p

Thanks... it was so obvious but ....
Mar 1 '06 #5

This discussion thread is closed

Replies have been disabled for this discussion.