[TYPO3-mvc] setTemplatePathAndFileName reverting to NULL

Franz Koch typo3.RemoveForMessage at elements-net.de
Tue Oct 19 18:49:23 CEST 2010


Hi,

>>> Not sure if this is your problem, but as far as I know, if the template
>>> matching your action name doesn't exist (even if you don't use it)
>>> extbase/fluid won't render it.  So for instance if you have updateAction(),
>>> which renders an email and then redirects to another action, update.html
>>> still has to exist (though it can be blank) in order to get your email html
>>> to render.  In my opinion this is a bug..
>>
>> that's right - that's the current behavior - but I don't think it's necessarily a bug. I suggest to use a custom view object to render the email content (that's what I always do).
>
> If it's not a bug, it must a missing feature. Not being able to use the standard view object (without trickery) for anything else than browser output is quite strange IMHO.
>
> Alternately, I would argue: if "everybody" has to write a custom view object to render non-browser output that custom object should be included in Fluid core.

don't get me wrong here - you don't need to create a custom viewObject, 
just a custom instance of the default fluid view object which is 
configured to use your mail templates.

If you don't like the way extbase is currently dealing with the 
viewObject, you could also override the resolveView method (the name of 
the method could differ - didn't have a look) and disable the part where 
extbase is setting it to an empty view if no template is found.

-- 
kind regards,
Franz Koch


More information about the TYPO3-project-typo3v4mvc mailing list