Review main Merged

95414[BUGFIX] Replace slashes when generating page slugs

Georg Ringer CR +2 V +2 Normal +177 −0 updated 09/02/26, 14:34

Commit message

The slug of a page is generated from its title, and a slash in that
title survived generation: a page titled "Terms / Conditions" ended
up with the slug "/terms-/-conditions", "Support 24/7" with
"/support-24/7" - the latter pretending a path segment that has no
page behind it.

The slug generator already supports a "replacements" option, which
is applied per field before the values are joined with the field
separator. The TCA of pages now uses it to turn a slash into the
configured fallback character "-".

Manually entered slugs keep their slashes, since replacements are
applied in SlugHelper->generate() only, not in ->sanitize().

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Oliver Klee +1
    • Andreas Kießling +1
    • Josua Vogel +1
  • Verified V +2 Done
    • Benni Mack +2
    • Oliver Klee +1
    • Josua Vogel +1
    • core-ci +1 CI

Issues 1

Files 3

Review log 911

  1. Georg Ringer uploaded patch set 1 08/25/26, 14:29

  2. Georg Ringer rebased onto patch set 2 08/25/26, 14:30

  3. core-ci voted on patch set 1 V +1 08/25/26, 14:37 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/107092

  4. core-ci voted on patch set 2 V +1 08/25/26, 14:38 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/107093

  5. Oliver Klee commented on patch set 2 V +1 08/25/26, 16:10

    Should we also backport this to 14.3 and maybe also 13.4?
  6. Georg Ringer commented on patch set 2 08/25/26, 16:30

    Reply

    IMO no as too much breaking/sudden change
  7. Oliver Klee voted on patch set 2 CR +1 08/25/26, 16:37

  8. Andreas Kießling commented on patch set 2 CR +1 08/25/26, 19:03

    Thanks a lot for taking care!
  9. Josua Vogel voted on patch set 2 CR +1 V +1 08/26/26, 05:49

  10. Benni Mack voted on patch set 2 CR +2 V +2 09/02/26, 14:34

  11. Benni Mack merged patch set 3 09/02/26, 14:34