For Programmers: Free Programming Magazines  


Home > Archive > PHP Pear > September 2005 > Re: [PEAR] Relative paths in DB_DO config.ini









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: [PEAR] Relative paths in DB_DO config.ini
Justin Patrin

2005-09-28, 6:58 pm

On 9/28/05, Jocke Selin <the.joxor@gmail.com> wrote:
> Hiya,
>
> Sorry if this has been asked before; but is it possible to use
> relative paths in the INI-file for DB_DataObject?
> The manual doesn't say much about it.
> http://pear.php.net/manual/en/packa...t.intro-config=

uration.php
>
> If it is possible, can anyone shed some light on from where the
> relative path should "start".
>
> The reason for asking is that if I build an application that's for
> distribution to several machines, relative paths, would save me
> editing the config files on all machines.
>


Did you try it? It *should* work, I think....

Another solution would be to not use an ini file. It's completely fine
to simply create an array in PHP and use that instead of parsing an
ini file. This way you could use dirname() or some other scripting to
calculate the path to use.

--
Justin Patrin
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com