Issue Bug Closed

#108164No link is being generated when passing empty string to f:link.action or f:uri.action ViewHelpers

Moritz Ngo 11/17/25, 14:09 updated 12/02/25, 11:48

Description

Task #107956 introduced the removal of code duplication of the f:link.action and f:uri.action ViewHelpers.

Prior to those changes, passing an empty string effectively resulted in an URL with the current page UID.
Now, when passing an empty string, no URL will be generated at all – when using f:link.action no <a>-Tag will be generated, which might break some templates and/or styling.

Not quite related to the bug reported above, but I saw that $pageUid will be handled differently in the following classes/methods:
  • TYPO3\CMS\Fluid\ViewHelpers\Uri\ActionViewHelper::createUriWithExtbaseContext
  • TYPO3\CMS\Fluid\ViewHelpers\Uri\PageViewHelper::renderWithExtbaseContext

Maybe we should unify the checks and handling for $pageUid

Reviews 2