[TYPO3-mvc] Tx_Extbase_MVC_Exception_InfiniteLoop
Marc Bastian Heinrichs
typo3 at mbh-web.de
Tue Jan 3 17:24:06 CET 2012
Hey,
Am 29.12.11 05:23, schrieb Mark Kuiphuis:
> <?php
> class Tx_TravelPrograms_Controller_OrderController extends
> Tx_Extbase_MVC_Controller_ActionController {
>
>
> /*
> * Displays a form for creating a new order
> *
> * @param Tx_TravelPrograms_Domain_Model_Program $program The selected program
> * @param Tx_TravelPrograms_Domain_Model_Order $newOrder The new order object
> * @dontvalidate $newOrder
> * @return string An HTML form for creating a new order
> */
> public function newAction(Tx_TravelPrograms_Domain_Model_Program $program,
> Tx_TravelPrograms_Domain_Model_Order $newOrder = NULL) {
>
> $referrals = $this->referralRepository->findAllReferrals();
>
> $this->view->assign('program', $program);
> $this->view->assign('newOrder', $newOrder);
> $this->view->assign('referrals', $referrals);
> }
>
> /*
> * @param Tx_TravelPrograms_Domain_Model_Program $program The selected program
> * @param Tx_TravelPrograms_Domain_Model_Order $newOrder A fresh newOrder object
> which has not been added to the repository yet
> * @return void
> */
> public function createAction(Tx_TravelPrograms_Domain_Model_Program $program,
> Tx_TravelPrograms_Domain_Model_Order $newOrder) {
> $this->orderRepository->add($newOrder);
> $this->redirect('show');
> }
>
> }
> ?>
>
> The @dontvalidate $newOrder is there, but I keep on getting this 101 infinite loop error
>
> The fluid form looks like this:
>
> <f:flashMessages />
>
> <f:form action="create" name="newOrder" object="{newOrder}" noCacheHash="true">
> <div>
> <f:form.hidden property="program" value="{program.uid}" />
> <f:form.hidden property="price" value="{program.price}" />
> </div>
> <div class="flabel">
> <label for="name"><f:translate key="name" /></label>
> </div>
> <div class="field"><f:form.textbox property="name" size="50" /></div>
>
> <div class="clear"></div>
>
> <div class="flabel">
> <label for="address"><f:translate key="address" /></label>
> </div>
> <div class="field"><f:form.textbox property="address" size="50" /></div>
>
> <div class="clear"></div>
>
> <div class="flabel">
> <label for="postcode"><f:translate key="postcode" /></label>
> </div>
> <div class="field"><f:form.textbox property="postcode" size="10" /></div>
>
> <div class="clear"></div>
>
> <div class="flabel">
> <label for="city"><f:translate key="city" /></label>
> </div>
> <div class="field"><f:form.textbox property="city" size="50" /></div>
>
> <div class="clear"></div>
>
> <div class="flabel">
> <label for="email"><f:translate key="email" /></label>
> </div>
> <div class="field"><f:form.textbox property="email" size="50" /></div>
>
> <div class="clear"></div>
>
> <!-- div class="flabel">
> <label for="newsletter"><f:translate key="newsletter" /></label>
> </div>
> <div class="field"><f:form.checkbox property="newsletter" value="0" /> <f:translate
> key="newsletter_info" /></div -->
>
> <div class="clear"></div>
>
> <div class="flabel">
> <label for="referral"><f:translate key="referral" /></label>
> </div>
> <div class="field"><f:form.select property="referral" options="{referrals}"
> optionValueField="uid" optionLabelField="title" /></div>
>
> <div class="clear"></div>
>
> <fieldset class="payment-methods">
> <legend><f:translate key="paymentTypes" /></legend>
> <div class="field">
> <f:form.radio class="radio" property="paymentType" value="1"
> checked="{payment.paymentType} == 1" /> <f:translate key="paymentType_Ideal" /><br/>
> <f:form.radio class="radio" property="paymentType" value="2"
> checked="{payment.paymentType} == 2" /> <f:translate key="paymentType_BankTransfer"
> /><br/>
> </div>
> </fieldset>
>
> <div class="clear"></div>
>
> <!-- div class="flabel"></div>
> <div class="field">
> <div style="float: left; margin-right: 5px;"><f:form.checkbox property="terms"
> value="1" /></div> <label for="terms-conditions"><f:translate key="terms-conditions"
> /></label>
> </div>
> <div class="field"><f:translate key="terms_info" /></div -->
>
> <div class="clear"></div>
>
> <f:form.submit class="submit" value="{f:translate(key: 'submit_order')}" />
> </f:form>
Where is the form field forwarding the program uid for mapping the
action argument $program in createAction? This is an required argument.
Perhaps here is error. Did you configured devIPmask correct, that you
can see a thrown exceptions in detail?
Best
Marc Bastian
More information about the TYPO3-project-typo3v4mvc
mailing list