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

Trailing Slash in Product URLs No longer working #7040

Closed
sitepodmatt opened this issue Oct 16, 2016 · 3 comments
Closed

Trailing Slash in Product URLs No longer working #7040

sitepodmatt opened this issue Oct 16, 2016 · 3 comments
Labels
Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed Progress: needs update

Comments

@sitepodmatt
Copy link

sitepodmatt commented Oct 16, 2016

We imported an M1 store to a fresh M2 (develop branch) with Magento Data Migration Tools. My clients store used /abc-product/ as the product detail URLs, the information populated correctly, including request_path in url_rewrite (i.e. trailing slash present), however all URLs 404 when clicked.

In my opinion app/code/Magento/UrlRewrite/Controller/Router.php (L132) should not be right trimming trailing slashes before passing to UrlFinder, this is causing problems with product search engine URLs that use the trailing space variety (as M1 supports).

The admin panel allows one to specify 'Product URL suffix' for Catalog as / Which correctly causes the product URL rendering for category/search pages to contain the trailing slash, however those product pages 404, because the trailing slash is stripped and doesn't match anything request_path in url_rewrite.

Believe this should be ltrim only.

sitepodmatt added a commit to sitepodmatt/magento2 that referenced this issue Oct 16, 2016
@sitepodmatt sitepodmatt reopened this Oct 16, 2016
@veloraven
Copy link
Contributor

@sitepodmatt thank you for your feedback.
Please, format this issue according to the Issue reporting guidelines: with steps to reproduce, actual result and expected result.
Please, also identify which version of Magento you are running.

@veloraven
Copy link
Contributor

According to contributor guide, tickets without response for two weeks should be closed.
If this issue still reproducible please feel free to create the new one: format new issue according to the Issue reporting guidelines: with steps to reproduce, actual result and expected result and specify Magento version.

@henk-hypershop
Copy link

Still issue is still not fixed in Magento 2.1.9. Seems like a very important one. If stores are indexed by Google with a trailing slash, one cannot simply migrate and contain the URL structure. This will be killing for rankings. Why has this not been fixed yet? We are now forced to change this in the vendor file with the risk that this will be overwritten on any update.

@magento-engcom-team magento-engcom-team added the Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed label Oct 4, 2017
magento-engcom-team pushed a commit that referenced this issue Aug 26, 2021
B2B-1875: Cannot import table rates CSV when S3 Remote Storage is enabled
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed Progress: needs update
Projects
None yet
Development

No branches or pull requests

4 participants