Пример #1
0
 public function createImageCaptchaAction()
 {
     $captcha = new Captcha($this->getRequest()->getSession());
     $captcha->outputImage();
     /*return new Response(
           $captchaText,
           200,
           array(
               'Content-Type' => 'image/png',
               'Cache-Control' => 'no-cache'
           )
       );*/
 }
Пример #2
0
 public function portadaAction()
 {
     $captcha = new Captcha($this->getRequest()->getSession());
     $captcha->build(realpath('bundles/comun/images') . '/captcha.png');
     return $this->render('ComunBundle:Default:portada.html.twig');
 }
Пример #3
0
 /**
  * @return Response
  */
 public function refreshImageAction()
 {
     // $this->refreshCaptcha();
     $captcha = new Captcha($this->getRequest()->getSession());
     $captcha->build(realpath('bundles/comun/images') . '/captcha.png');
     //return  $this->render('ComunBundle::captcha.html.twig', array('time' => time()));
     return $this->render('ComunBundle::captcha.html.twig');
 }