RE: [PHP] ini_set() broken?

From: Date: Mon, 08 Jul 2002 03:44:06 +0000
Subject: RE: [PHP] ini_set() broken?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-106017@lists.php.net to get a copy of this message
On Mon, 8 Jul 2002, Martin Towell wrote: >>> <? >>> if(ini_set("register_globals", "0")) >>> echo "ini_set success"; >>> else >>> echo "ini_set failed"; >>> ?> > >I haven't tried this code Then why comment on it? >but I assume you're trying to say that "ini_set >failed" is displayed, but you're expecting the other output to be displayed. >Am I correct there? Yes, is it not obvious enough from just reading the code? I am showing that the ini_set() function is not working properly, as per the manual. The manual states that ini_set() returns the old value on success and FALSE on failure. My script always returns false. Any idea why? >What happens if you use http://localhost/file.php?var=something >or whatever >your test script's path is and have this line at the end of the script > echo "var = |$var|"; What does this prove or disprove in relation to the ini_set() function? If you knew anything about the function then you would see I am passing it a big fat zero in the second parameter, just as the manual states I can. I also tried "Off" and "off", same results. >does $var contain anything. If it doesn't, then ini_set() worked... >otherwise.. um... find other way of doing it(??) Yes.. another way, any suggestions? -- ----------------------------------------------------------------------- Greg Donald http://destiney.com/public.key -----------------------------------------------------------------------

« previous php.general (#106017) next »