Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SEO URLs result in incorrect pathing, lack of 404s (OC 1.5.6.3) #1435

Closed
DarthAutocrat opened this issue May 14, 2014 · 0 comments
Closed

SEO URLs result in incorrect pathing, lack of 404s (OC 1.5.6.3) #1435

DarthAutocrat opened this issue May 14, 2014 · 0 comments

Comments

@DarthAutocrat
Copy link

\catalog\controller\common\seo_url.php

Due to the way the lookups work, it is possible to access a page with variant paths.
if you have the about_us page set as "about_us" for the URL,
you can access the page via;
"/about_us" (correct)
"/about_us/test" (wrong)
"/test/about_us" (wrong)
"/test/about_us/test" (wrong)

similar applies to categories with SEO URLs.
You can have a parent category "cat1"
you can access it via;
"/cat1" (correct)
"/cat1/test" (wrong)
"/test/cat1" (wrong)
"/test/cat1/test" (wrong)

Same applies for nested cats (parent>child{+>})
"/cat1/cat2/cat3" (correct)
"/cat1/cat2/cat3/test" (wrong)
"/cat1/test/cat3/" (wrong)
"/test/cat3/" (wrong)
"/test/cat3/test" (wrong)

Multiple "correct" URLs can also be used, with the "last correct" being the displayed one. Thus if you have 2 products "imac" and "ipod";
"/ipod/imac"
will display the imac product page.
(Fortunately, product pages have a canonical link element)

All of these can cause Canonical issues for SEO.
Even though products have the Canonical Link Element, it is still a URL that works that should not)

Options:

  1. Ensure Canonical Link Elements are deployed throughout content (information pages, categories and products).
  2. Stronger mapping of SEO URLs in the DB (save "chains" rather than singular cat id?)
  3. Stronger SEO_URL code to check pathing and more decisive handling
  4. Consider altering "responses" depending on situation (we could strip erroneous data and return a 301, or we could simply return a 404).

There is some code to help handle some of the erroneous requests, but it would need expanding to cover other eventualities.
There are also some alterations to include a Canonical Link Element on non-product pages (the categories and information pages).
This should be incorporated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants