• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Retriving data from a db with an Ajax call

#1
[eluser]GabrieleMartino[/eluser]

The controller is simple

Code:
public function video_download ($page_id){
            header('Content-Type: application/x-json; charset=utf-8');
            $to_share = $this->chats_model->catch_shared_video($page_id);
            return json_encode($to_share);
}



#2
[eluser]GabrieleMartino[/eluser]
The answer is that is just

Code:
echo json

and not return


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.