PDA

View Full Version : Static html pages from queried php


G-man
Mon 17th May '04, 1:32pm
I have a directory that people search using php. Since search engine bots can't navigate a php search system I believe I need to create html pages that they can navigate that will get the directory listed.

I know this or something like this can be done but I am drawing a blank.

Can someone point me in the right direction?

ramprage
Mon 21st Jun '04, 11:39am
Use mod_rewrite and have one results page, then have one article viewing page.
Feed the variables to display the article to viewingpage.php like this:

view.php?id=15&cat=25
Then you can create a simple rule with mod_write for Apache to change the URL to look like a static html page.

/dir/15/25.html

But for best search engine results, don't use numbers. Instead use the page name or category name. Check out how I used it at http://www.ramprage.com/

http://www.ramprage.com/beginner/skateboard_beginners is the category
http://www.ramprage.com/beginner/skateboard_beginners/1/54 is the article

All of this is from index.php there is no actual directory called "beginner" or "skateboard_beginners"

:D

Stadler
Mon 21st Jun '04, 3:53pm
You can find a nice tutorial at http://www.sitepoint.com/article/search-engine-friendly-urls :)