Re: Including files from another site

From: Date: Mon, 17 Apr 2006 23:07:54 +0000
Subject: Re: Including files from another site
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-234136@lists.php.net to get a copy of this message
""Richard Lynch"" <ceo@l-i-e.com> wrote in message news:11473.67.108.68.36.1145312034.squirrel@www.l-i-e.com... > On Mon, April 17, 2006 5:45 am, Shaun wrote: >> I have created a CMS where all sites on our server are administrated >> from >> one central site, and HTML content is stored in the CMS database. >> >> I want users to all control their sites database functions from the >> CMS >> site, but I want to keep the database and database admin scripts in >> the >> individual website account to keep things simple. So I need want to be >> able >> to include these scripts within the CMS site but keep them secure. I >> have >> tried using frames but I can't keep a session going in the database >> admin >> scripts, is there a better way to do this? >> >> Any advice would be greatly appreciated. > > If you trust the source, you could just do: > > <?php > include > 'http://example.com/central_core_files_shared_by_all.inc'; > ?> > > Or, if all these sites are on the same box, you don't even need to use > HTTP for the include... > > Exactly what are you trying to secure against? > > You make it sound like "keep them secure" is an absolute. It's not. > It's relative. > > -- > Like Music? > http://l-i-e.com/artists.htm Hi Richard, The security issue is important because I don't want anyone to be able to use the websites database admin scripts without logging into the CMS first. Otherwise anyone who happened to type in www.oneofmywebsites.com/cms would be able to make unwanted changes to that particular sites database. In answer to your second question both sites will be on the same box...

« previous php.general (#234136) next »