Review main Ready for review Stale

80536[TASK] Add target for live search links

Guido Schmechel CR 0 V 0 Normal +89 −4 updated 09/15/26, 19:37

Commit message

It is now possible to set a target attribute to search result actions.
For security reasons the targets `_self`, `_parent` and `_top` are
disallowed to prevent opening the action target in the same frame as
the TYPO3 backend runs. The check is case-insensitive, as browsers
treat these keywords, and the target is opened with `noopener`, so the
opened page gets no reference to the backend window.

Test this change

Run a command in your clone of the TYPO3 Core. Then try what the change does and vote on Verified in Gerrit. How to review a patch

Check out patch set 5
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/36/80536/5 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/36/80536/5 && git cherry-pick FETCH_HEAD

Review

  • Code review CR 0 Needs a vote
  • Verified V 0 Needs a vote
    • core-ci +1 CI

Merge conflicts 7

Issues 1

Files 7

Review log 913

  1. Guido Schmechel uploaded patch set 1 08/12/23, 20:47

  2. core-ci voted on patch set 1 V +1 08/12/23, 20:54 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45426

  3. Benni Mack updated the commit message in patch set 2 V +1 10/18/24, 14:11

  4. Andreas Kienast commented on patch set 2 CR -1 01/09/25, 11:22

    I like the idea, but that won't work. Clicking a search item action invokes the event `livesearch:invoke-action`, which is handled in `@typo3/backend/live-search/element/result/result-container.ts`. This event handler expects a custom action handler, which may open a new window (to reflect the hypothetical scenario in your issue). If no custom action handler is given, it falls backs to opening the URL in the content frame.
  5. Guido Schmechel commented on patch set 2 01/10/25, 14:53

    Reply

    Is there even a realistic chance of implementing such a feature? Or should we set the patch to Abandon?
  6. Andreas Kienast commented on patch set 2 01/10/25, 14:57

    Reply

    I have to think about this in a broader scope.
  7. Andreas Kienast uploaded patch set 3 CR -1 01/21/25, 15:13

  8. core-ci voted on patch set 3 V +1 01/21/25, 15:19 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/72792

  9. Guido Schmechel commented on patch set 3 CR +1 V +1 02/02/25, 12:57

    I was so free and give +1 for the change of Andreas, even if the initial patch was created by me. Tested with an own DictionaryProvider. Example: https://github.com/ayacoo/examplesearch/blob/v14/Classes/LiveSearch/DictionaryProvider.php
  10. Benni Mack updated the commit message in patch set 4 CR +1 V +1 04/22/26, 06:30

  11. core-ci voted on patch set 4 V -1 04/22/26, 07:01 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/100712

  12. Georg Ringer uploaded patch set 5 V -1 09/15/26, 19:29

  13. core-ci voted on patch set 5 V +1 09/15/26, 19:37 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/108637