SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Wizard frank1's Avatar
    Join Date
    Oct 2005
    Posts
    1,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    mod rewrite not working in online server

    we have htaccess file as this
    RewriteEngine On
    RewriteBase /new

    RewriteRule ^.*/.*-news([0-9]+)\.html$ http://www.xyz.com/new/news.php?news_id=$1

    RewriteRule ^.*/.*-article([0-9]+)\.html$ http://www.xyz.net/new/article.php?article_id=$1 [L]


    This works fine in localhost..
    in online server...
    after mod rewrite..(then we click on rewritten html link) it is again directed to php page ie news/news.php?news_idp=1

    i think the mod rewrite is on in server as html redirect is not failing...
    so where can be problem...please help

  2. #2
    SitePoint Enthusiast
    Join Date
    Mar 2006
    Location
    Canada
    Posts
    56
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    what server are you using ?

    maybe it's IIS ?
    Thai Boxing
    E-Pix
    Chaaban
    Tekfirm Want to have a web site ?

  3. #3
    SitePoint Wizard silver trophybronze trophy Stormrider's Avatar
    Join Date
    Sep 2006
    Location
    Nottingham, UK
    Posts
    3,133
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Well IIS doesn't have mod_rewrite, it's an apache module, and it doesn't use .htaccess files.

    This would probably be better off being asked in the apache forum - I don't know enough about mod_rewrite, maybe it has some options that are different?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •