application/controllers/Dashboard.php
//inserting new muncipality to the database
inserting new muncipality to the database
inserting new muncipality to the database
public function addMunicipality(){
	 		if($_POST['name'] != "" && $_POST['dist_id'] != ""){
	 			$data['name'] = $_POST['name'];
	 			$data['district_id'] = $_POST['dist_id'];
	 			$ret = $this->dashboard_model->Add($data,'municipality');
	 		}else{
	 			$ret = "All fields should be filled up!";
	 		}
	 		echo $ret;
		 }
public function addMunicipality ( ) { if ( $ _POST [ 'name' ] != " " && $ _POST [ 'dist_id' ] != " " ) { $ data [ 'name' ] = $ _POST [ 'name' ] ; $ data [ 'district_id' ] = $ _POST [ 'dist_id' ] ; $ ret = $ this -> dashboard_model -> Add ( $ data , 'municipality' ) ; } else { $ ret = " All fields should be filled up! " ; } echo $ ret ; }
inserting new muncipality to the database
inserting new muncipality to the database