79696062

Date: 2025-07-09 18:08:48
Score: 0.5
Natty:
Report link

i had some faults in my code that is why i was not getting the results.

first i was using

 return $.get("<?php echo base_url('get_testname'); ?>", { query: query }, function (data) {

which should be $.post() so i changed to

return $.post("<?php echo base_url('get_testname'); ?>", { query: query }, function (data) {

secondly i was using check in my controller method instead of query so i changed the check to query

public function get_doctor()
{
    $query = $this->input->post('query');
    $data = $this->customers->get_doctor($query);
    echo json_encode( $data);
}
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: ieesab