#102468Linkvalidator doesn't check record/custom links within RTEs at all
Description
I was wondering why EXT:linkvalidator 11 wasn’t checking “record links” and “custom link types” and found this after debugging the matter a while.
There’s a big switch statement in TypolinkSoftReferenceParser (which is used for typolink fields such as tt_content.header_link):
switch ((string)$tLP['type']) {
case LinkService::TYPE_EMAIL:
case LinkService::TYPE_TELEPHONE:
case LinkService::TYPE_URL:
case LinkService::TYPE_FOLDER:
case LinkService::TYPE_FILE:
case LinkService::TYPE_PAGE:
case LinkService::TYPE_RECORD:
default:
$event = new AppendLinkHandlerElementsEvent($tLP, $content, $elements, $idx, $tokenID);
}
if ($linkDetails['type'] === LinkService::TYPE_FILE && preg_match('/file\?uid=(\d+)/', $matches[1], $fileIdMatch)) {
} elseif ($linkDetails['type'] === LinkService::TYPE_PAGE && preg_match('/page\?uid=(\d+)#?(\d+)?/', $matches[1], $pageAndAnchorMatches)) {
} elseif ($linkDetails['type'] === LinkService::TYPE_URL) {
} elseif ($linkDetails['type'] === LinkService::TYPE_EMAIL) {
} elseif ($linkDetails['type'] === LinkService::TYPE_TELEPHONE) {
}Reviews 4
Related issues 3
History 58
-
Sybille Peters changed Related to #94086 <span data-processor="relativetime" data-value="2024-03-15T09:10:43+00:00" > 03/15/24, 09:10 </span>
-
Sybille Peters commented <span data-processor="relativetime" data-value="2024-03-15T09:46:17+00:00" > 03/15/24, 09:46 </span>
-
Sybille Peters changed Related to #103403 <span data-processor="relativetime" data-value="2024-03-15T09:46:30+00:00" > 03/15/24, 09:46 </span>
-
Sybille Peters changed Related to #106661 <span data-processor="relativetime" data-value="2025-05-07T08:21:20+00:00" > 05/07/25, 08:21 </span>
-
Gerrit Code Review pushed patch set 1 for main to change 96008 status
NewUnder Review <span data-processor="relativetime" data-value="2026-09-23T17:15:48+00:00" > 09/23/26, 17:15 </span> -
Gerrit Code Review pushed patch set 12 for main to change 89312 <span data-processor="relativetime" data-value="2026-09-24T04:43:48+00:00" > 09/24/26, 04:43 </span>
-
Gerrit Code Review pushed patch set 1 for 14.3 to change 96051 <span data-processor="relativetime" data-value="2026-09-24T21:38:15+00:00" > 09/24/26, 21:38 </span>
-
Sybille Peters commented and changed status
Under ReviewResolved done0 %100 % <span data-processor="relativetime" data-value="2026-09-24T21:45:12+00:00" > 09/24/26, 21:45 </span>Applied in changeset commit:04dcbbe70067ce7f217dc672cadca5f52978d0d9.
I could reproduce this in a TYPO3 v12 installation using news with configured custom linkhandler as described in https://docs.typo3.org/p/georgringer/news/main/en-us/Tutorials/BestPractice/Linkhandler/Index.html#linkhandler
I think there are 2 unrelated problems:
1. the link parsing problem you described: custom links with typolink tags (as in RTE records) are not being parsed due to TypolinkTagSoftreferenceParser. I could reproduce this by adding 2 custom links, one as a URL in header_link (t3://record?identifier=tx_news&uid=99999), one by adding a link in the RTE:
I then set a breakpoint in linkvalidator InternalLinktype::checkLink. This will be called if the link is in header_link, not for RTE.
2. There is no Linktype for custom “record” link types in Linkvalidator or rather the InternalLinktype which could also check custom links, does not, it only accepts “pages” and “tt_content”. For this, I created a seperate issue: #103403
https://github.com/TYPO3/typo3/blob/5c95229af666e4ce39dd5a22baecd3390d649c49/typo3/sysext/linkvalidator/Classes/Linktype/InternalLinktype.php#L85
Can you confirm?
Would you like to create a patch for this?
It also seems to me, this used to work, but I am not sure.
IMHO, no 1 (this issue) is not a linkvalidator problem, it is a problem in the core link parsing. This probably also results in no references being created in the reference index. Frontend rendering is not affected.