?
Current File : /home/c/i/d/cideo/site_2015/application/modules/site/controllers/AjaxController.php
<?php
class AjaxController extends Zend_Controller_Action
{
  public function init()
  {

     $ajaxContext = $this->_helper->getHelper('AjaxContext');
     $ajaxContext->addActionContext('newsinsc', 'json')->initContext();



  }

 public function postDispatch() {

    $this->getResponse()->clearBody();
    $this->getResponse()->setHeader('Content-Type', 'text/x-json');
    $this->getResponse()->setHeader('Charset', 'utf8');
    $this->getResponse()->setHeader('X-Robots-Tag', 'noindex, nofollow');

}

  public function newsinscAction()
  {
		require_once("mailchimp/Liste.php");



		//$email=$this->getRequest()->getPost('email');
		$email = $this->_request->getParam('email');



		$list = new Liste;

		//$email=$this->getRequest()->getPost('email');
		


	        $result = $list->addsuscriber($email, "via Site");

		$this->view->result = $result;

		//$this->view->result = $result ;

  }


}