Bug #100758
openViewhelpers and other things do not work outside of extbase context
0%
Description
Using f:form* or f:*.action viewhelpers does not work anymore outside of extbase context. For instance within StandaloneView or FLUIDTEMPLATE.
StandaloneView is regularily used for rendering e-mail and there of course links should be generated.
It should be checked if this still works:
- f:form viewhelper do correctly prefix the fieldnames. E.g. having an non-extbase plugin using StandaloneView the prefix should be like `tx_myext_pi1[name]` for a name input field
Collection of notes from other forge issues:
f:form - Exception:
(1/1) #1639821904 RuntimeException
ViewHelper f:form can be used only in extbase context and needs a request implementing extbase RequestInterface.
/vendor/typo3/cms-fluid/Classes/ViewHelpers/FormViewHelper.php line 148
f:link.action - Exception
(1/1) #1639818540 RuntimeException
ViewHelper f:link.action can be used only in extbase context and needs a request implementing extbase RequestInterface.
/vendor/typo3/cms-fluid/Classes/ViewHelpers/Link/ActionViewHelper.php line 81
In both cases the "TYPO3\CMS\Core\Http\ServerRequest object" is in the $request instead the RequestInterface.
Updated by Christian Kuhn over 1 year ago
- Related to Bug #100759: f:translate does not take overrides of labels in TypoScript into account anymore added
Updated by Christian Kuhn over 1 year ago
- Related to Bug #100760: f:translate: Provide possibility to set a default extensionName added
Updated by Christian Kuhn over 1 year ago
all three issue were planned as such. they're not bugs.
if changed again, they need proper decision, impact and analysis before. just stating different than before is not good enough.
Updated by Markus Klein over 1 year ago
Please consider that planning might have been insufficient and mistakes can happen.
"different than before" in this case means breaking basic stuff that has been working for years and is relied on by others outside the Core.
Updated by Jo Hasenau over 1 year ago
Christian Kuhn wrote in #note-3:
all three issue were planned as such. they're not bugs.
If so, where is the deprecation notice, that tells people this would be breaking change(s) in TYPO3 12?
Didn't find one in the official Fluid docs, where just the documentation of f:form changed in v12 but nothing pointed to those changes in v11.
If changed, they need proper decision, impact, analysis and deprecation before. Just stating planned as such is not good enough. #SCNR
Updated by Jo Hasenau over 1 year ago
It would have been easy to just remove the Extbase dependency from the ViewHelpers too with #98377, since they worked with the fake ExtbaseRequest presented by Standalone Fluid anyway - instead they are documented as requires an Extbase-Request now.
Updated by Jo Hasenau over 1 year ago
- Related to Task #98377: Avoid Extbase Request init in StandaloneView added
Updated by Česlav Przywara about 1 year ago
- Has duplicate Bug #101141: f:form and f.link.action request implementing ServerRequest instead of RequestInterface added
Updated by Lina Wolf about 1 year ago
What is the recommended way to link to an Extbase Action from non-Extbase context now? We need to offer a migration path
Updated by Stefan Bürk about 1 year ago
- Related to Task #101729: [TASK] Allow f:link.action and f:uri.action without Extbase added
Updated by Xavier Perseguers 12 months ago
Just hitting this bug after working on migrating EXT:cf_google_authenticator to TYPO3 v11 and now starting pushing up to TYPO3 v12.
This extension uses a StandaloneView whose template depends on a VH I just created for TYPO3 v11 and bangs! this crashes in TYPO3 v12.
Updated by Kai Tallafus 10 months ago
So, how to migrate f:form and f:link.action outside of an extbase context?
Updated by Julian Mair 9 months ago
Do you have a planned solution, or perhaps a workaround or migration path?
Updated by Mathias Brodala 7 months ago
Please see the related ticket #98377 and its changelog entry for details: