Jump to content

Custom SEO URL Paths Causing Search To Fail


whirringcogs

Recommended Posts

In CC5.2.8 I'm getting a 404 file not found error when using search on some site pages. I have 'Enable SEO URLs' turned on. The problem only seems to occur on category or product pages where the Custom SEO URL Path includes a directory, rather than just the category or product name on its own.

IE: a search for a category or product with a Custom SEO URL Path such as "christening-wear/shawls" fails, while a search for a category or product with a Custom SEO URL Path such as simply "shawls" works fine.

Setting "Enable SEO URLs" to 'Off' seems to solve the problem.

Pages whose Custom SEO URL Path includes a directory, search using the following type of URL:

www.treasuredfavours.co.uk/catalogue/christening-wear/index.php?_a=category&search[keywords]=search term&x=11&y=9

Pages whose Custom SEO URL Path does not include a directory, search using the following type of URL:

www.treasuredfavours.co.uk/catalogue/index.php?_a=category&search[keywords]=search term&x=8&y=3

Inserting that category name into the search URL would appear to be the problem.

While it's possible to remove the directory names from the Custom SEO URL Path for some categories and products, others stubbornly refuse to be modified in the Search Engines tab.

Does anybody have any thoughts on this? I'd rather not have to resort to turning "Enable SEO URLs" to work around this problem.

Link to comment
Share on other sites

Problem solved. Here's the solution, which may be helpful for others.

The search problem, as noted, was caused by forward slashes in Custom SEO URL Paths.

There were a number of Product Names in the database which included slashes, so these were removed from the names, and the Custom SEO URL Paths were checked to make sure no slashes remained.

The problem with Category Names appeared to be caused by identical category names existing in the database. So duplicates were renamed, and the Custom SEO URL Paths were checked to make sure only the category name was showing, and not the full path to the directory, including slashes.

Once a duplicate Category name was changed, it was possible to modify the Custom SEO URL Path, which previously were effectively 'locked'.

A quick way to see which categories and products contain slashes is to look at the database Table structure for table `xzc_CubeCart_seo_urls`.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...