[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [cobalt-users] Upgrading from RaQ4 to RaQ550



> 
> So what am I going to do with users who have cgi's using
> /home/sites/siteMM/
> I tell people not to do that. I guess they have to be changed to
> /home/sites/www.domain.com/
> 
> Gerald

Hi Gerald,
In anticipation of moving sites to other machines, I use the 
document root to set a basedirectory in any script.
This works fine except if the script is to be run from
an ssh session (then there is no document root).

eg. 
$BaseDir=$ENV{'DOCUMENT_ROOT'};
$BaseDir=~ s#/web##;
Then I prefix any filename or directory in the script
with $BaseDir.
eg. $ImageDir="$BaseDir/images";
It keeps things nice and tidy.

On a RAQ2 the document root is 
/home/sites/sitexxx/web

Then $BaseDir would be set to 
"/home/sites/sitexxx"

Looking at your note above
(/home/sites/www.domain.com/)
It should work on a RAQ4 too.

I know it's after the horse has bolted, but should
be helpful for future scripts.

Paul