Issue Bug Closed

#96431Redirect to 404 if entry point is fully qualified domain

Christian Toffolo 12/24/21, 15:44 updated 11/06/26, 09:02

Description

Suppose we have a website address https://www.example.com

To reproduce:
  • have a Site Configuration with a language set with
base: 'https://www.example.es/'
  • translate a page with title “test-default” with that language
  • change the title of the translated page “test-es”
Result:
a new sys_redirect record is created with source_host www.example.com instead of www.example.es.
So when an user browses the default language of this translated page:
https://www.example.com/test-default
is redirected to:
https://www.example.com/test-es
that doesn’t exist and throws a 404.

Correct redirect link should be:

https://www.example.es/test-es

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.

History 4

  1. Christian Toffolo changed subject Wrong redirect source_host if entry point is full qualified domain Redirect to 404 if entry point is fully qualified domain category target version PHP Version 7.4 <span data-processor="relativetime" data-value="2022-02-17T19:54:50+00:00" > 02/17/22, 19:54 </span>

  2. Benni Mack commented and changed status New Closed <span data-processor="relativetime" data-value="2026-11-06T09:02:27+00:00" > 11/06/26, 09:02 </span>

    Duplicate of #89328, fixed in 10.4 and v11 (October 2021): automatic redirects take their source host from the base of the page’s site language, and the target links to the page in that language, so a language with its own domain gets redirects on that domain. Covered by SlugServiceTest::rebuildSlugsForSlugChangeRenamesSubSlugsAndCreatesRedirectsWithLanguages(). Please reopen if this still happens on a current version.