Apply this code in your Codeigniter’s controller.
Change:
<?php
public function FunctionOne(){
$user_id=$this->input->get(“user_id”);
FunctionTwo($user_id);
}
?>
TO:
<?php
public function FunctionOne(){
$user_id=$this->input->get(“user_id”);
echo $this->FunctionTwo($user_id);
}
?>
Define second function end of the first function or any where in Controller
<?php
public FunctionTwo($user_id){
echo $user_id;
}
?>
Question and answer is powered by AnsPress.io