can't load page in development environment Symfony2 -
i working on website on signupaction method, registers user. of sudden, signup page won't load anymore, welcome page loads perfectly.
i did not edit code loads page, edited code when tries signup (i.e. clicking on form submit button).
i tried clear cache no succes. did not include code cause caused else.
link seek acces:
http://localhost/socpronetbeans/web/app_dev.php/signup
route:
login_login_signup: path: /signup defaults: { _controller: loginloginbundle:default:signup }
this link works perfectly:
http://localhost/socpronetbeans/web/app_dev.php/login
this code causes problem:
$teamarr = $this->getdoctrine() ->getrepository('loginloginbundle:team') ->findall(); $check = false; while ($check == false){ foreach($teamarr $oneteam){ if(empty($oneteam->getuseruserid())){ $team = $oneteam; break; } } }
this infinite loop:
while ($check == false){ // $check never true foreach($teamarr $oneteam){ if(empty($oneteam->getuseruserid())){ $team = $oneteam; break; // breaks foreach loop } } }
to prevent executing infinitely, must manipulate $check
have truthy value or redo loop.
symfony2
No comments:
Post a Comment