Re: articles in database ????

From: Date: Tue, 18 Jul 2000 23:00:07 +0000
Subject: Re: articles in database ????
References: 1 2 3 4  Groups: php.db php.general 
Request: Send a blank email to php-db+get-1257@lists.php.net to get a copy of this message
Hi, Ask them. If they use Apache with Virtual Domains, it will work. If not, you can get almost the same effect by having the script which inserts articles in the database create a short file for each article. For example, when creating article "whyphprocks", you could have it be a really short script (e.g., at http://my.magazine.com/articles/whyphprocks): <? include("show.php"); ?> And then have PHP parse the BASE_URL to find out the article name. As mentioned, the script that inserts the article in the database would just write out the short file for each article entered. Ciao, Andreas Jeff Gannaway wrote: > > At 07:31 AM 7/18/00 -0400, Andreas Pour wrote: > >I mean you would use the RewriteRule to change something like > >"http://www.magazine.com/articles/billgatesbites" > >to > > >>"http://www.magazine.com/show.php?art=billgatesbites". > > That way when > >you add articles to the database you can reference them (externally) as > >a regular URL, but you only need one script to display them (the > >show.php script would get the value of 'art' and look up the article in > >the database and display it; the user need never know about the show.php > >script). > > > >For more info on Rewrite rules, see > >http://www.apache.org/docs/misc/rewriteguide.html. > > This sounds very cool. I scanned the URL you posted and was wondering if > you could only use it for the entire server or if it could be set for each > domain name on a server? Like many designers, I rent space from a web > hosting company. If they have installed this module, can it be set up with > rules just for my domain?? > > Thanks! > Jeff Gannaway

« previous php.db (#1257) next »