Re: root_url and http_host

Mike Gifford <[email protected]> 09 Apr 2003 10:49:28 -0400
Newsgroups gmane.comp.cms.phpslash.devel
Organization OpenConcept Consulting http://www.openconcept.ca
Message-ID <[email protected]>
On Wed, 2003-04-09 at 10:40, Joe Stewart wrote:
> On Tue, Apr 08, 2003 at 08:39:43PM -0400, Mike Gifford wrote:

<snip>

> > Now the convention is (I think) that all of the scripts in the /admin/
> > directory call on 'config.php' in that directory which calls up the
> > '../config.php' script, right?  So couldn't you just fillet out the
> > extra rooturl?
> > $_PSL['rooturl'] = str_replace('/admin/', "/", $_PSL['rooturl']);
> > Or am I missing something...
> The navbar arrays are defined in rooturl/config.php.  So their links 
> are screwed up when in the admin directory.

Drat..

> This is inside the called config.php.  So defining rooturl in the 
> admin/config.php before or after won't help.

How much of a resource drag would it be to put this in the
rooturl/config.php file?
$_PSL['rooturl'] = str_replace('/admin/', "/", $_PSL['rooturl']);

Don't imagine that it would inconvenience too many folks if they
couldn't set up a root url within an /admin/ directory..

There are other apps that have done this..  If I have a chance and find
some good example code I'll send it along..  But this isn't a critical
function..

Mike
-- 
Mike Gifford <[email protected]>
OpenConcept Consulting http://www.openconcept.ca



-------------------------------------------------------
This SF.net email is sponsored by: Etnus, makers of TotalView, The debugger 
for complex code. Debugging C/C++ programs can leave you feeling lost and 
disoriented. TotalView can help you find your way. Available on major UNIX 
and Linux platforms. Try it free. www.etnus.com