On Jul 20, 2004, at 9:44 PM, Gerald Richter wrote:
If the files have different path _and_ different package names it will work.
If the files have no package name, it will compiled into the first package
where it is loaded and only accessable from this package/file.
Hi Gerald,
The include file has no package name. But I left out one crucial part of my example that makes all the difference. :-) Once I require the unique (per virtualhost) include file I then stuff the variables into the $req object. So if I have 5 virtualhosts then mod_perl will cache the 5 different include files and my module will put the correct values into $req depending on which site is being accessed.
At least that's my theory! :-) However Andrew's way is probably better, which is to put the db connect info into the environment (per virtualhost in httpd.conf) and then pull the constants from a database table.
But in any case, will the method I suggested work? As I said before I'm doing all of this testing on one virtualhost and haven't rolled any of it out to my real sites yet. So I want to catch this stuff as soon as possible.
Cheers, John
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]