Kryptronic Software Support Forum

You are viewing this forum as a guest. Login to an existing account, or create a new account, to reply to topics and to create new topics.

#1 08-19-2009 01:02:44

craigp
Member
From: Alaska
Registered: 01-12-2007
Posts: 65
Website

.htaccess rule from Wiki breaks ccp0- links

This is important for those of you upgrading CCP 6 sites to CCP 7.

I had put the following rules into my .htaccess in order to rewrite incoming CCP 6 URLs to CCP 7 pages, as found in the Wiki.

Code:

RewriteRule ^ccp0-display/(.*)\.html$ cms-display/$1\.html [R=permanent]
RewriteRule ^ccp0-dynform/(.*)\.html$ cms-dynform/$1\.html [R=permanent]
RewriteRule ^ccp0-(.*)/(.*)\.html$ ecom-$1/$2\.html [R=permanent]

I did some testing by using ccp0- format links to see if they would rewrite properly.  On all prodshows and catshows, it causes an error message (page not found, use the menu to continue).  The site displays, but content area contains only the error message.

When the following rule is removed, the links will work properly and display the correct prod or cat pages:

Code:

RewriteRule ^ccp0-(.*)/(.*)\.html$ ecom-$1/$2\.html [R=permanent]

I also experimented with the display and dynform rules.  They appear to be necessary for rewriting those URLs.  When removed, ccp0- links to display or dynform pages don't work.

Therefore, I am using the first two of those rules in my .htaccess:

Code:

Options +FollowSymLinks
RewriteEngine on

RewriteRule ^ccp0-display/(.*)\.html$ cms-display/$1\.html [R=permanent]
RewriteRule ^ccp0-dynform/(.*)\.html$ cms-dynform/$1\.html [R=permanent]

Last edited by craigp (08-19-2009 17:04:53)

Offline

 

Board footer