FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » newbie question: Is config.php necessary?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: newbie question: Is config.php necessary? [message #170611 is a reply to message #170606] Wed, 10 November 2010 08:53 Go to previous messageGo to previous message
Erwin Moller is currently offline  Erwin Moller
Messages: 228
Registered: September 2010
Karma:
Senior Member
On 11/9/2010 9:21 PM, Thomas Mlynarczyk wrote:
> Erwin Moller schrieb:
>
> [Overriding PHP settings in an included config file]
>> // magic quotes off please
>> "magic_quotes_gpc" => "",
>
> I'm afraid this cannot be set within a PHP script. The manual lists this
> directive as PHP_INI_PERDIR (used to be PHP_INI_ALL up to PHP 4.2.3). I
> think the filter functions provide a means of accessing the "unquoted"
> raw input.

Correct. That was confusing.
But it is there for a reason. ;-)
The reason it is there anyway is: the following block (that checks the
values) produces an error in case magic_quotes_gpc is on.

(I had a few more ini-values in there, but cut a lot out. The code was
only posted to show the idea of the kind of things you can do in a
'global config' file.)


>
>> // errorhandling
>> "error_reporting" => E_ALL
>
> I would use E_ALL | E_STRICT (unintuitively, E_STRICT is not included in
> E_ALL, so E_ALL is actually "E_ALMOST_ALL").

Yes, I am aware of E_ALL and E_STRICT: this examplecode comes from a
project where I didn't want strict errors to error out. The errorhandler
itself even returns if it is a strict error.
So in this case I ignore them two times. ;-)

Regards,
Erwin Moller


>
> Greetings,
> Thomas
>


--
"There are two ways of constructing a software design: One way is to
make it so simple that there are obviously no deficiencies, and the
other way is to make it so complicated that there are no obvious
deficiencies. The first method is far more difficult."
-- C.A.R. Hoare
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Variable expansion <?=$foo?> not working anymore
Next Topic: need urgent help
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Wed Nov 27 20:15:52 GMT 2024

Total time taken to generate the page: 0.06733 seconds