[TYPO3-mvc] Value empty in Fluid but not in Controller?

Oliver Wand wand at itaw.de
Tue Apr 26 20:02:42 CEST 2011


Hi Bastian,

thanks for your fast response :-)

> Are you sure, that..

No, what? :-)

> 1. you are in the right action

Yep:

public function listAction() {
	$questions = $this->questionsRepository->findAll();
	$this->view->assign('questions', $questions);

	foreach ($questions as $question)
	{
		var_dump($question->getTitle());
	}
}

and list.html:

<f:for each="{questions}" as="{question}">
	<f:link.action action="show" arguments="{question : question}">
		{question.title}
	</f:link.action>
</f:for>


> 2. that you assigned the value to the view
> ($this->view->assign('question', $question))

see above

> does
> <f:debug>{question}</f:debug>
> return anything?

Just "| debug |"


Cheers,

Oliver


More information about the TYPO3-project-typo3v4mvc mailing list