Scott answered a question about *web programming* on Aardvark!

Question
May 25, 2010
Sent to Aardvark via IM
Friend 1
31 / M / Mumbai, IN
Say I have web pages with titles and I want to generate seo friendly urls for them. For example, if the title is "The monsoon is on its way" then I would try to generate a url from the title such as http://example.com/monsoon-is-on-its-way . The pages have a original url that consists of paramters such as page_number etc. One way of doing this is by using the htaccess file with rewrite rules. This is not a great solution as I have to write one rule for each page and there are tens of thousands of pages. Do you know of any alternative techniques to achieve the same?

*seo*

seo, pretty-url

I am using LAMP stack
  • Answer 1
    + 11 minutes
    Aardvark found someone who knows about web programming

    Hhbuzk9q_1280326287
    Scott S.
    M / Canberra ACT, AU
    Knows about: WSS
    When I have done such a thing I have used mod_rewrite http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html
    Friend 1
    31 / M / Mumbai, IN
    Thanks!

    I believe this approach uses the .htaccess file. I actually have tens of thousands of pages and plan to maintain all of them. So if the .htaccess files is used, it is soon going to become pretty large and I'll start taking a hit via disk access.
    Hhbuzk9q_1280326287
    Scott S.
    M / Canberra ACT, AU
    Knows about: WSS
    check out the front controller pattern, http://onlamp.com/pub/a/php/2004/07/08/front_controller.html
    Friend 1
    31 / M / Mumbai, IN
    This is useful stuff man. Much appreciated.

    Mithun
    Hhbuzk9q_1280326287
    Scott S.
    M / Canberra ACT, AU
    Knows about: WSS
    no worries mate, hope it helps

What is Aardvark?

Aardvark discovers the perfect person in your network to answer any question in minutes.

How do I ask a question?

  • Just send Aardvark an IM, email or tweet with a question — or ask from vark.com
  • Aardvark will send you a response from someone in your network within minutes

Share this page

 
x