[ic] Removing cgi-bin/cat and ?id=<session_id>

Ronald Colcernian rcc at Dresults.Com
Sat Feb 13 22:06:20 UTC 2010


I've been told removing the cgi-bin/cat component of URL's and the 
session ?Id=<session_id> string helps improve search engine listings.

If true, I lived a pretty tough journey to almost accomplish the removal 
or masking and I need a sanity check from the pro's.

To accomplish this I've done the following:

1) Added Apache Rewrite rules as recommended in one of the Archived 
Emails. (Works as expected.)

2) Changed file: catalog/products/variable.txt variable CGI_URL to a 
blank string. (Kinda works as expected.)

3) Changed file: interchange.cfg variable Mall to no. (When set to yes 
it causes the path in the cookie to have a value of "cgi-bin/cat" 
instead of "/", which causes the Server.pm code to eventually append the 
?id=<session id> to the URLs anyway, in spite of the above changes.)

4) The following variables were already set in my catalog.cfg file:
ScratchDefault  mv_add_dot_html   1  
ScratchDefault  mv_no_session_id  1
ScratchDefault  mv_no_count       1


So after all of this, when you go to www.domain.com/index.html the index 
page still renders all of the URL's with the id=<session_id> suffixed. 
But if you click on any URL the next page render without id=<session_id> 
suffixed, assuming you have cookies enabled, and thats fantastic and 
exactly what you want. Well almost!

(I have studied the source code and because there is no cookie set when 
handling the first rendering of index.html, the source code adds the id= 
string until it knows that cookies are enabled in the users browser, and 
when enabled id= disappears on the following page turns.)

Wouldn't we want the first rendering of the index.html page to render 
URL's without the id string?  Isn't that one of the more important pages 
for the search engine?

If so, I have started and not yet finished modifying Server.pm, and 
Session.pm to make the assumption that the end user has cookies enabled, 
and writing some JavaScript to test if the browser has cookies enable, 
and if not post this information automatically to tell interchange that 
oops no cookies for this user/session better append id? and then render 
index.html with id= suffixed.

It just feels like somebody else has solved this and I'm going about 
this the hard way, and perhaps not in a way that will actually work?

The apprentice asks his master for guidance.

Ron




More information about the interchange-users mailing list