ajax 呼び出しを行い、phpfoxで応答として何かを取得しようとしています。
JS:
$.ajaxCall('module.check_whether_first_time',
'u_id='+u_id+'&my_user_id='+my_user_id).done(function(data) {
alert(" data = " + data )
});
ajax が ajax.class.php 内から呼び出す関数:
public function check_whether_first_time(){
$u_id = $this->get('u_id');
$my_user_id=$this->get('my_user_id');
// processing with data goes here
$counter=1;
echo $counter;
}// end of function check_whether_first_time
変数の値$counter
を取得したい。data
コードは機能しませんが、FireBug は応答として結果が返されない ajax 要求を示しています。方法は何ですか?