Project

General

Profile

Actions

Task #92693

closed

Deprecate Linktype LinkHandler in linkvalidator

Added by Sybille Peters over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Should have
Category:
Linkvalidator
Target version:
-
Start date:
2020-10-23
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
11
PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

This checks links by the extension "linkhandler", which is outdated, see https://extensions.typo3.org/extension/linkhandler/

Additionally, the configuration option and some references in the documentation should be fixed.


Related issues 2 (1 open1 closed)

Related to TYPO3 Core - Task #96170: Remove linkvalidator TSconfig optionClosedOliver Bartsch2021-11-30

Actions
Related to TYPO3 Core - Feature #103403: Make it possible to check custom record links with linkvalidatorUnder ReviewSybille Peters2024-03-15

Actions
Actions #1

Updated by Gerrit Code Review over 3 years ago

  • Status changed from New 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/+/66265

Actions #2

Updated by Gerrit Code Review over 3 years 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/+/66265

Actions #3

Updated by Gerrit Code Review over 3 years 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/+/66265

Actions #4

Updated by Sybille Peters over 3 years ago

The ext:linkhandler is outdated, but the functionality was integrated into the core in version 9.5: Feature: #79626 - Integrate record link handler

The question is if the LinkHandler class still works as intended and what kind of links it covers (as external, file and db (internal) are already covered by the other linktypes.

Actions #5

Updated by Sybille Peters over 3 years ago

Q: Can LinkHandler linktype be deprecated or even removed?

yes:

The LinkHandler linktype expects links that start with record:

public function fetchType($value, $type, $key)
    {
        if ($value['type'] === 'string' && strpos(strtolower($value['tokenValue']), 'record:') === 0) {
            $type = 'linkhandler';
        }
        return $type;
    }

It apppears, this is outdated in any case:

if ($result['type'] === LinkService::TYPE_RECORD) {
                [$a['identifier'], $tableAndUid] = explode(':', $linkHandlerValue, 2);
                $tableAndUid = explode(':', $tableAndUid);
                if (count($tableAndUid) > 1) {
                    $a['table'] = $tableAndUid[0];
                    $a['uid'] = $tableAndUid[1];
                } else {
                    // this case can happen if there is the very old linkhandler syntax, which was only record:<table>:<uid>
                    $a['table'] = $a['identifier'];
                    $a['uid'] = $tableAndUid[0];
                }
                $result = array_merge($result, $a);
            }


typo3/sysext/core/Classes/LinkHandling/LegacyLinkNotationConverter.php
Actions #6

Updated by Gerrit Code Review over 3 years ago

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/+/66265

Actions #7

Updated by Gerrit Code Review over 3 years 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/+/66265

Actions #8

Updated by Gerrit Code Review over 3 years 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/+/66265

Actions #9

Updated by Gerrit Code Review over 3 years ago

Patch set 7 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/+/66265

Actions #10

Updated by Sybille Peters over 3 years ago

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

Updated by Benni Mack over 3 years ago

  • Status changed from Resolved to Closed
Actions #12

Updated by Oliver Bartsch over 2 years ago

  • Related to Task #96170: Remove linkvalidator TSconfig option added
Actions #13

Updated by Sybille Peters 5 days ago

  • Related to Feature #103403: Make it possible to check custom record links with linkvalidator added
Actions

Also available in: Atom PDF