dec($task);}} switch($task) { case "default": $this->fn_default_newticketc(); break; case $task: $task="fn_".$task; if(method_exists($this,$task)){$this->$task();} break; default: $this->fn_default_newticketc(); break; } } public function fn_default_newticketc() { echo $this->FN_CREATEHEADER(); $tiketnumber=$_REQUEST['tiketnumber']; $childspassenger=$_REQUEST['childspassenger']; $idtiketpassenger=$this->fn_get_fieldvalue("id","select id from ".DB_APORTIL.".tbl_passenger_tiket where tiketnumber='$tiketnumber'"); echo ""; echo ""; echo $this->FN_CLOSEHEADER(); echo $this->FN_CREATEBODY("e8f1ff"); echo "
".$this->CREATE_LINK('window.location.reload();','REFRESH','javascript:void(0)','_self','','','','')."
".$this->CREATE_IMAGE("loadergrid.gif")."
Notes : - Double click row for edit
"; echo $this->FN_CREATEFOOTER(); } public function fn_grdrecord() { $idtiketpassenger=$_REQUEST["idtiketpassenger"]; header("Content-type: text/xml"); echo(''); echo ""; $qry="select * from ".DB_APORTIL.".tbl_passenger_childs where idtiketpassenger='$idtiketpassenger' and isdeleted=0 order by id asc limit ".TBL_PAGE_LIMIT; $rs=$this->selectquery($qry); if($rs) { $i=1; while($row=$this->data_row_array($rs)) { echo (""); print(""); print(""); print(""."]]>"); print(""); print(""."]]>"); print(""."]]>"); print(""."]]>"); echo (""); $i+=1; } } else { // echo mysql_errno().": ".mysql_error()." at ".__LINE__." line in ".__FILE__." file
"; echo "error at ".__LINE__." line in ".__FILE__." file
"; } echo "
"; } public function fn_delchilds(){ $id=$_REQUEST['id']; $qry="update ".DB_APORTIL.".tbl_passenger_childs set isdeleted=1,remarkdeleted='Cancel by user ',dby='".$_SESSION['nik']."',ddt=now() where id='$id'"; if($this->executequery($qry)){ echo "ok|"; } else{ echo "failed|Failed remove child"; } } } ?>