[TYPO3-mvc] view renderer ignores action argument
g4-lisz at tonarchiv.ch
g4-lisz at tonarchiv.ch
Tue Oct 11 22:56:23 CEST 2011
Hi there,
in my action controller method i want to decide which template is going
to be displayed.
This is because the layout looks a little bit different dependent of the
search demand:
public function resultsAction(Tx_Myext_Domain_Model_SearchDemand $demand) {
[...]
if ($demand->getSpecialDemands() !== NULL) {
$action = 'resultsExtended';
echo "Extended";
}
else
$action = NULL;
[...]
$this->view->attach(...);
$this->view->render($action);
}
If the template "ResultsExtended.html" does not exists, the rendere
complains about this.
If it does exist, the template "Results.html" is displayed in place of
"ResultsExtended.html".
I.e. in the end it's always the default layout which is rendered.
Is there a solution to my problem?
Thank you,
Till
More information about the TYPO3-project-typo3v4mvc
mailing list