Re: Relative paths in DB_DO config.ini
| From: | Justin Patrin | Date: | Wed, 28 Sep 2005 21:38:30 +0000 |
| Subject: | Re: Relative paths in DB_DO config.ini | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-21138@lists.php.net to get a copy of this message | ||
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/package.database.db-dataobject.intro-configuration.php¬ëIÂ
q†Ìám
> ÃŒlœ¾
>
> 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