Forum Moderators: phranque

Message Too Old, No Replies

Mod Rewrite Reversal

Mod_Rewrite Reversal

         

solokron

10:05 pm on Sep 23, 2008 (gmt 0)

10+ Year Member



How would I inverse these two rules?

RewriteRule ^knowledgebase/([0-9]+).html$ /index.php?_m=knowledgebase&_a=view&parentcategoryid=$1 [L]
RewriteRule ^knowledgebase/view/([0-9]+)(/[^\.]+)?.html$ /index.php?_m=knowledgebase&_a=viewarticle&kbarticleid=$1 [L]

Thank you!

solokron

10:08 pm on Sep 23, 2008 (gmt 0)

10+ Year Member



To clarify, I removed a plug in that required those rewrites. Now Google links to those URLs are producing 404s. I want to reverse the rules so when the previous links are looked for it redirects to the normal format.

Any help would be appreciated!

jdMorgan

12:57 am on Sep 24, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Does this thread [webmasterworld.com] help? See the section of the code example with the comment "Externally redirect client requests for old dynamic URLs to equivalent new static URLs"

Jim

solokron

7:35 pm on Sep 24, 2008 (gmt 0)

10+ Year Member



Hello Jd,

It would actually be the opposite of that.

jdMorgan

8:38 pm on Sep 24, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Read all three steps, please. Saves a lot of needless repetition, and will save you time if you understand the whole process.

Post specific questions back here in this thread.

Jim