Re: Global or include?

From: Date: Wed, 05 Jan 2011 22:45:12 +0000
Subject: Re: Global or include?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-310514@lists.php.net to get a copy of this message
On Jan 5, 2011, at 4:40 PM, Paul Halliday wrote: > Say you have 10 or so scripts and a single config file. If you have > main.php, functions1.php, functions2.php, functions3.php.. > > Does is hurt to do an include of the config file in each separate > script, even if you only need a few things from it, or should you > just specify what you want with a 'global' within each > script/function? > > Thanks! > > -- > Paul Halliday > http://www.pintumbler.org I think that OOP would solve this particular problem best.

« previous php.general (#310514) next »