|
Posted by Erwin Moller on 11/05/97 11:32
Freebird wrote:
> Hello you all, -]
>
> I've done a script that will work in many different servers, and now, I
> need to create the install script, where all the tables will be created,
> and the paths will have to be setted.
>
> Is there something that will help me with that ?
>
> What is the best solution for the PATHS when a script will run in many
> different servers ?
> How to best use the paths in this case..
>
>
> TKs for your help
>
> Freebird
Hi Freebird.
Are you talking about databases or paths to your files?
Both need a different approach.
FILES:
If you want to make sure were PHP will search for included files, the
easiest way is to overwrite include-path in each of your scripts.
(I use a script that is included everywhere on a site, you I do not have to
set the include-path globally by modifying php.ini, but application-based.)
Read more here:
http://nl2.php.net/manual/en/ini.core.php#ini.include-path
DATABASE:
This might be more problematic to answer in a general way.
Do you want scripts to produce a database for Postgresql only?
Or mySQL only? Or both? Or for every database in existence?
Sometimes Database Abstraction Layers offer a generalized way for creating
databases of different types. (So you only have to say that you target
MS_SQL eg for a certain installation).
I know ADODB has these options.
(I expect PEAR:DB too, allthough I never use it.)
In case you just target 1 database, I would suggest you just deliver all the
relevant SQL-statements specific for that database, because that is by far
the easiest method.
Regards,
Erwin Moller
Navigation:
[Reply to this message]
|