title: Parse error: syntax error, unexpected $end, expecting T_FUNCTION in ClmsRegistrationModel.php
body: <pre><code>    &lt;?php
  /**
   * clmsRegistration
   * 
   * @author MGUCS-07
   * @version 
   */
  require_once 'Zend/Db/Table/Abstract.php';
  class ClmsRegistrationModel extends Zend_Db_Table_Abstract
  {
      /**
       * The default table name 
       */
      protected $_name = "clms_registration";
      protected $_primary = "user_name";
  
  
      public static function changePassword($username, $newpassword)
      { //changes the password
          try {
              $chps= new ClmsRegistrationModel();
              $row = $chps-&gt;find($username);
              $row1 = $row-&gt;current();
              $row1-&gt;password=$newpassword;
              $row1-&gt;save();
          }
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }       
      }
  
      public static function checkUsed($username)
      {  //check whether used or not
          try {
          $table = new ClmsRegistrationModel();
          $row=$table-&gt;find($username);
          if($row)
          {
              return 1;
          }}
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }   
  
      }
  
      public static function deleteUser($user_name)
      { //deletes a user
          try { 
              $deluser=new ClmsRegistrationModel();
              $row = $deluser-&gt;find($user_name);
              $row1=$row-&gt;current();
              $result = $row1-&gt;delete();
          }
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }   
      }
  
      public static function updateUser($user_name,$district,$email_id,$phone_number)
      {
          //updates the details of the user
          try {
              $upUser = new ClmsRegistrationModel();
              $row = $upUser-&gt;find($user_name); 
              $row1=$row-&gt;current();
              $row1-&gt;district= $district;
              $row1-&gt;email_id= $email_id;
              $row1-&gt;phone_number= $phone_number;
              $row1-&gt;save();
          }
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }
  
      }
  
      public static function getRole($user_name)
      { //gets the role of the user
          try {
              $roq= new ClmsRegistrationModel();
              $u= $roq-&gt;fetchRow($roq-&gt;select()-&gt;where('user_name=?',$user_name));
              return $u-&gt;toArray();
          }
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }   
  
      }
  
      public function isActive($user_name)
      { //select active user
          try {
              $roq = new ClmsRegistrationModel();
              $u= $roq-&gt;fetchRow($roq-&gt;select()-&gt;where('user_name=?',$user_name));
              return $u-&gt;toArray();
          }
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }   
      }
      public function setActive($user_nam)
      { //sets user active 
          try {
              $roq = new ClmsRegistrationModel();
              $row= $roq-&gt;find($user_nam);
              $row1=$row-&gt;current();
              $row1-&gt;user_name= $user_nam;
              $row1-&gt;status1 = 1;
              $row1-&gt;save();
          }
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }   
      }
      public static function setRole($user_name,$role)
      { //sets the role of the user
          try {
              $reg=new ClmsRegistrationModel();       
              $row = $reg-&gt;find($user_name);
              $row1= $row-&gt;current();
              $row1-&gt;role_organization=$role;
              $row1-&gt;save();
          }
          catch (Zend_Db_Exception $e)
          {
              $e-&gt;getMessage();
          }   
      }
  
      public function  register($uname,$pass,$role,$en,$status,$email,$ph,$date,$dis)
      {// function  for registration purposes
  
           try{
  
              $reg = new  ClmsRegistrationModel();
              $row =$reg-&gt;fetchNew();
              //$row= $row-&gt;current();
              $row-&gt;user_name = '$uname';
              $row-&gt;password = '$pass';
              $row-&gt;role = $role;
              $row-&gt;employee_name=$en;
              $row-&gt;status1=$status;
              $row-&gt;email_id =$email;
              $row-&gt;phone_number =$ph;
              $row-&gt;date =$date;
              $row-&gt;District=$dis;
              $row-&gt;employe_id =$row-&gt;employe_id +1;
              $row-&gt;save();
              //$reg-&gt;save();
           }
           catch (Zend_Db_Exception $e){
              $e-&gt;getMessage();
           }
  
  
  }
  }
  </code></pre>
  
  <p>This is my model class and getting that error.
  Please tell why this error and how to debug it.</p>