Improving your WebSphere Commerce SEO Redirects in V7

If you are on V7 of WebSphere Commerce and not making use of it’s SEO functionality then you are missing a trick.  This can ensure that you map out the usual parameters in a Commerce request, to something that looks much better and works for SEO and most people Google.  This is managed from several different tables when it comes to products and categories.  More data is contained when you create your own mappings, but this article looks at how you can use SEO redirects for categories and products.

SEOURL – Holds the mapping between the category and product tokens and the values for them from the catentry and catgroup tables.

SEOURLKEYWORD – Links to the SEOURL table on the SEOURL_ID and provides the keyword entry and mobile keyword for the language, storeent and if the entry is active or not.

SEOREDIRECT – This holds the relationship between an old keyword and a new keyword when you change over your entries, and it’s here that you can do some clever things.

The functionality within WebSphere Commerce manages adding entries into these tables when you run the SEOURLKEYWORDGEN, this includes entries when you change the SEO tag on a category or a product.  It will then insert an entry into the SEOREDIRECT table, which contains the old keyword and the new keyword.

When you then access the website using the old keyword instead of having to put entries into your webserver for redirects, WebSphere Commerce will do this for you.  Even better you can then keep track of how many times the redirect is used via the SEOREDIRECTTRAFFIC table, and have the system clean up those entries no longer needed when they get no hits over a period of time.

Now this works great if you change an existing category or product but what about if you create a brand new category and move your products around or want to go from an old product to a new product.  Nothing is automated in this case because the SEOURLKEYWORDGEN utility is just looking at existing categories or products for changes.

Instead what you need is a little manual intervention.

1) identify the old entry in the SEOKEYWORD table and make a note of it’s SEOURLKEYWORD_ID, and then set it’s status to 0 so it is inactive.  The inactive is important otherwise the SEO functionality will keep using the entry and not redirecting

2) Identify the new entry in the SEOKEYWORD (after you have run the keyword generation command) and make a note of it’s SEOURLKEYWORD_ID.

3) Add an entry into the SEOREDIRECT table give it a unique ID and add in the old SEOKEYWORD_ID and the new one.

4) Go into the admin console (8002) for the site and refresh the registry so the SEO data is updated.

Now on the site access with your old SEO URL and you should find it’s redirected to the new one.  if you get any problems then trace this component*=all

It will only show entries if the trace actually works so if you are seeing nothing in the trace, then it means you have missed something on the setup and registry update.

Leave a Reply

Your email address will not be published. Required fields are marked *