.htaccess - How to re-direct blog article URLs? -


i trying redirect bunch of old blog article urls using .htaccess file:

redirectmatch ^/index\.php/global/article/(.*)$ http://www.mywebsite.com/blog/article/$1 

this doesn't work, however, because cms seems confused index.php bit , keeps adding ?symphony-page= urls.

it's part responsible:

### frontend rewrite - ignore files , folders rewritecond %{request_filename} !-d rewritecond %{request_filename} !-f rewriterule ^(.*\/?)$ index.php?symphony-page=$1&%{query_string}    [l] 

can help?

please try following (comments included explain):

rewriteengine on  # first, redirect old uris new ones via 301 redirect. # allow cms take on using rules follow. rewriterule ^index.php/global/article/(.+)$ /blog/article/$1 [l,r=301]  # frontend rewrites - cms rewritecond %{request_filename} !-d rewritecond %{request_filename} !-f rewriterule ^(.*\/?)$ index.php?symphony-page=$1&%{query_string} [l] 

Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -