mod rewrite multiple sites one server

Discussion in 'Apache' started by mickjbud, May 22, 2006.

  1. #1
    Hi all

    I have a single server hosting multiple sites one been static and two been dynamic database driven. How do I use mod rewrite so that the static site is not affected and the other two site are independently affected by the mod rewrite. I have googled and seen the option of htaccess but i am not sure how or if it is the right way.

    The main reasons I wish to do this is for SEO and tidyness. I am using Debian Linux - Apache server(2.0.54).

    Example

    http://www.mysite.com/thisfile.php?thisitem=amount&thisitem2=result2

    would be better for both the user and more importantly SE if it read

    http://www.mysite.com/thisfile/thisfile

    Both dynamic sites obviously have different Urls and both have different database arguments. Is there a way to use mod rewrite on both without affecting the other sites?

    Also can I test this on my loacal server which is XP running apache?

    TIA

    Regards

    Mick
     
    mickjbud, May 22, 2006 IP
  2. theblight

    theblight Peon

    Messages:
    246
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #2
    hi mick,

    Just put the htaccess to where the dynamic scripts is located and your done.

    Hope it Helps
     
    theblight, May 23, 2006 IP