.. include:: /Includes.rst.txt .. _feature-95176: ========================================================== Feature: #95176 - Introduce view helper ========================================================== See :issue:`95176` Description =========== Using Fluid view-helper :html:`` provides capabilities to resolve `t3://` URIs, which is used in backend contexts as well. Internally :html:`` relies on an existing frontend context, with corresponding TypoScript configuration in :typoscript:`lib.parseFunc` being given. In order to separate concerns better, a new :html:`` view helper has been introduced * to be used in frontend and backend context without relying on TypoScript, * to avoid mixing parsing, sanitization and transformation concerns in previously used :php:`ContentObjectRenderer::parseFunc` method of the frontend rendering process. Impact ====== Individual TYPO3 link handlers (like `t3://` URIs) can be resolved and substituted without relying on TypoScript configuration and without mixing concerns in :php:`ContentObjectRenderer::parseFunc` by using Fluid view-helper :html:``. Syntax ------ :html:`` * `selector`: (optional) comma separated list of node attributes to be considered, for example `subjects="a.href,a.data-uri,img.src"` (default `a.href`) * `onFailure` (optional) corresponding behavior, in case transformation failed, for example URI was invalid or could not be resolved properly (default `removeEnclosure`). Based on example :html:`value`. corresponding results of each behavior would be like this: + `removeEnclosure`: :html:`value` (removed enclosing tag) + `removeTag`: :html:`` (removed tag, incl. child nodes) + `removeAttr`: :html:`value` (removed attribute) + `null`: :html:`value` (unmodified, as given) Example ------- .. code-block:: html visit
visit
... will be resolved and transformed to the following markup ... .. code-block:: html visit
visit
.. index:: Backend, Fluid, Frontend, ext:fluid