Re: articles in database ????

From: Date: Tue, 18 Jul 2000 10:47:10 +0000
Subject: Re: articles in database ????
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-7051@lists.php.net to get a copy of this message
Jeff Gannaway wrote: > > At 03:43 PM 7/17/00 +0100, Nick wrote: > >Basically, I was hesitating about whether to put stuff like the actual > article text (BLOLB/ TEXT) directly into the databse, or whether to put it > in a seperate TXT or HTML file in a sepcified directory, bearing in mind > the articles would have to be searchable. > > Without knowing in advance the size and quantity of articles, my > inclination would be to avoid putting them inside the database for these > reasons: > > 1. You can write a text search function that would read the articles for > occurrences of a string using the > strstr command. Right, but a database can search the articles as well. And probably do so faster. > 2. Assuming this is for a public site, there would be MANY benefits to > making your articles indexable by other search engines, namely more traffic > to your site :) Not sure I follow this argument. Regardless of how you store the articles, they would be retrievable with a URL. If the concern is that some search engines don't index pages with query strings, you just quickly set up Apache w/ mod_rewrite such as: RewriteRule ^/articles/(.*)$ /articles/show.php?art=$1 [P] Which would convert the article information to a query string for your php script "show.php". Ciao, Andreas

« previous php.general (#7051) next »