If the search engine optimization (SEO) feature is enabled, when you create a
new extended sites store and sales catalog, you must also manually create a token to store the new
URL keyword mapping for the SEO-friendly URL creation.
Every SEO-friendly URL uses a
token that represents the combination of store and catalog in its construction.
Update the SEOURL and SEOURLKEYWORD tables with new tokens when you create the
following stores or catalogs:
- A new sales catalog in the extended sites catalog asset store and you want to use this sales
catalog with the existing extended sites stores. A token is needed for new sales catalog plus
existing extended site store
- A new extended sites store with a catalog asset store that has existing sales catalogs. A token
is required for the new extended sites store and the existing sales catalog combination
Important: Keep keywords unique between extended sites and any catalog asset store
that they share.
Extended sites may use SEO keywords that were defined at either the extended
site level or the catalog store level. For instance, consider two extended sites that both use the
keyword 'coffee' for a category. One defines the keyword locally and the other looks up the
definition in the category asset store, which applies 'coffee' to a different category. If the
second extended site is accessed first, the SEO service will cache its version of 'coffee.' This
definition of 'coffee' will be used in subsequent calls, including calls to the first extended site,
until the cache is cleared.
Procedure
- Ensure that your SEOURL table has a Store/Catalog token
entry for the master catalog.
If the master catalog is
missing, add the token to the
SEOURL and
SEOURLKEYWORD tables with these SQL
statements:
INSERT INTO seourl (seourl_id, tokenname, tokenvalue) values (<seourl_id>, 'StoreToken:CatalogToken', '<storeId>:<masterCatalogId>');
INSERT INTO seourlkeyword (seourlkeyword_id, seourl_id, language_id, storeent_id, urlkeyword) values (<seourlkeyword_id>, <seourl_id>, <langId>, 0, '<urlkeyword>');
For example:
INSERT INTO seourl (seourl_id, tokenname, tokenvalue) values (-2000, 'StoreToken:CatalogToken', '11051:10001');
INSERT INTO seourlkeyword (seourlkeyword_id, seourl_id, language_id, storeent_id, urlkeyword) values (-2000, -2000, -1, 0, 'Saturn IT Master');
Note: For
<storeid>, use the store id
of your
Extended Sites Catalog Asset Store. To
find the store id, run the following SQL statement:
select * from storeent;
- For each WebSphere Commerce extended sites store, issue
the following SQL statement. This statement adds a Store/Catalog token
to the SEOURL table.
INSERT INTO seourl (seourl_id, tokenname, tokenvalue) values (<seourl_id>, 'StoreToken:CatalogToken', '<storeId>:<salesCatalogId>');
For example:
INSERT INTO seourl (seourl_id, tokenname, tokenvalue) values (201, 'StoreToken:CatalogToken', '11251:10401');
Important:
- Ensure that you use the token name StoreToken:CatalogToken
- Ensure that the token values are <storeId>:<salesCatalogId>, where
<storeId> is the store id of your extended site store.
- For each WebSphere Commerce extended sites store, issue
the following SQL statement. This statement adds a URL keyword to
the SEOURLKEYWORD table that
represents both the store id and the catalog id:
INSERT INTO seourlkeyword (seourlkeyword_id, seourl_id, language_id, storeent_id, urlkeyword) values (<seourlkeyword_id>, <seourl_id>, <langId>, 0, '<urlkeyword>');
For example:
INSERT INTO seourlkeyword (seourlkeyword_id, seourl_id, language_id, storeent_id, urlkeyword) values (201, 201, -1, 0, 'teststore');
- Repeat step 2 and step 3 for each additional WebSphere
Commerce extended sites store that you want SEO enabled.
- Refresh the SEOConfigurationRegistry.
Results
All extended sites stores now have SEO-friendly URLs.