2

I want to change my url from

http://intervideo.2watt.net/component/content/article.html?id=65&Itemid=479

to

http://intervideo.2watt.net/component/content/article.html?id=65&Itemid=332

I have tried the following code but it is not working

RewriteRule ^/?Itemid=479/(.*)$ Itemid=332/$1 [R=301,L]

1 Answer 1

1

You cannot capture query string from RewriteRule. Use a RewriteCond instead:

RewriteCond %{QUERY_STRING} ^(id=\d+)&Itemid=479$ [NC]
RewriteRule ^component/content/article\.html$ %{REQUEST_URI}?%1&Itemid=332 [L,NC,R=302]
Sign up to request clarification or add additional context in comments.

1 Comment

Thanks for the answer ::)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.