Exemplo n.º 1
0
 public function regionsAction()
 {
     if ($this->_getParam('term', false)) {
         $regions = new Counties();
         $response = $regions->getRegions($this->_getParam('term'));
     } else {
         $response = array('id' => NULL, 'term' => 'No county specified');
     }
     echo Zend_Json::encode($response);
 }
Exemplo n.º 2
0
 /** Get the regions list
  * @access public
  */
 public function regionsAction()
 {
     if ($this->getParam('term', false)) {
         $regions = new Counties();
         $response = $regions->getRegions($this->getParam('term'));
         echo Zend_Json::encode($response);
     } else {
         throw new Pas_Exception_Param($this->_missingParameter, 500);
     }
 }