Bug #89091

Page with a slug with trailing slash results in 404

Added by Sybille Peters almost 2 years ago. Updated 18 days ago.

Status:
Resolved
Priority:
Should have
Assignee:
-
Category:
Link Handling, Site Handling & Routing
Target version:
-
Start date:
2019-09-05
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

TYPO3 9.5.9

Possible scenario

  1. URL should be /other
  2. someone enters /other/ in slug field
  3. Neither /other or /other/ works: you get a 404

Related issues

Related to TYPO3 Core - Bug #86055: pages.slug always removes the trailing slashClosedBenni Mack2018-08-31

Actions
Related to TYPO3 Core - Feature #89552: Redirect URLs with trailing slashes to their canonical non-trailing-slash URL (or the other way around)New2019-10-30

Actions
Related to TYPO3 Core - Bug #88544: Trailing slash gets added to "homepage" urls if base is without trailing slashAccepted2019-06-12

Actions
#1

Updated by Benni Mack about 1 year ago

  • Status changed from New to Needs Feedback

Hey Sybille,

do you have a Route Enhancer configured or this is a plain installation?

#2

Updated by Gerrit Code Review about 1 year ago

  • Status changed from Needs Feedback to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/64655

#3

Updated by Gerrit Code Review about 1 year ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/64655

#4

Updated by Gerrit Code Review about 1 year ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/64655

#5

Updated by Sybille Peters 9 months ago

No, I did not configure a route enhancer. It should be reproducible out of the box.

#6

Updated by Riccardo De Contardi 9 months ago

I think it is still reproducible on both 9.5.21 and 10.4.8 (just plain TYPO3 with default configuration)

#7

Updated by Sybille Peters 8 months ago

  • Status changed from Under Review to New
#8

Updated by Ralf Merz 6 months ago

Hi,
I can confirm the behavior in current v10.4.10. I'm currently upgrading a v8 to v10. We have removed sys_templates etc. to move everything into site configuration.
We have a PageType RouteEnhancer in place, but I can reproduce the 404 when I remove it.
In .htaccess I got some rules to forward to URLs with trailing slash only, to prevent duplicate content. But even when I use the default htaccess I can reproduce 404.
Please ping me (maybe in Slack also) if I can help to find out more etc.

Thx and cheers
merzilla

#9

Updated by Sybille Peters 6 months ago

  • Subject changed from Entering a slug with a trailing slash results in 404 to Page with a slug with trailing slash results in 404
#10

Updated by Sybille Peters 6 months ago

Would it be an option to have an eval setting for pages.slug that does not allow a trailing slash OR that the trailing slash is automatically removed when saving?

I don't know if there is any scenario where a trailing slash would actually be required in the pages.slug field.

#11

Updated by Sybille Peters 6 months ago

  • Related to Bug #86055: pages.slug always removes the trailing slash added
#12

Updated by Sybille Peters 6 months ago

  • Related to Feature #89552: Redirect URLs with trailing slashes to their canonical non-trailing-slash URL (or the other way around) added
#13

Updated by Sybille Peters 6 months ago

  • Related to Bug #88544: Trailing slash gets added to "homepage" urls if base is without trailing slash added
#14

Updated by Gerrit Code Review about 1 month ago

  • Status changed from New to Under Review

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/64655

#15

Updated by Gerrit Code Review about 1 month ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/64655

#16

Updated by Gerrit Code Review about 1 month ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/64655

#17

Updated by Gerrit Code Review 18 days ago

Patch set 1 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/69373

#18

Updated by Benni Mack 18 days ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
#19

Updated by Gerrit Code Review 18 days ago

  • Status changed from Resolved to Under Review

Patch set 2 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/69373

#20

Updated by Benni Mack 18 days ago

  • Status changed from Under Review to Resolved

Also available in: Atom PDF