#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2009
    Posts
    95
    Rep Power
    9

    Rewrite still showing old URL in address bar


    Hi,

    I am trying use some nice and simple syntax to hide the dynamic URLs within my site.

    Clicking the links which use the new/SEO-Freindly URLs works fine and it take them to the right dynamically generated page, BUT the dynaic URL is being shown in the address bar, not the new/SEO-Friendly one.

    Here is my htaccess file code:

    Code:
    Options +FollowSymLinks
    RewriteEngine on
    
    Redirect /post/new-seo-friendly-url/ /post.php?id=1
    RewriteRule /post/new-seo-friendly-url/ /post.php?id=1
    So when I click on:

    mysite.com/post/new-seo-friendly-url/
    It does take me to:

    mysite.com/post.php?id=1
    Like I want, but I want to see:

    mysite.com/post/new-seo-friendly-url/
    In the address bar, not:

    mysite.com/post.php?id=1
    Could anyone provide me any assistance here?

    Thank you very much.
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2015
    Posts
    75
    Rep Power
    3
    This may sound silly and this answer is very late, so you've probably solved your problem, but have you tried clearing your browser cache/cookies or opening the site in incognito/in-private browsing?

IMN logo majestic logo threadwatch logo seochat tools logo