September 17, 2014
codeigniter + Ajax (亲测)

(E文,没时间翻译)
首先做一个Ajax的helper,下面是说明,很简单,粘贴复制就可以了。。。
<?php if (!defined('BASEPATH')) exit('No direct script access allowed');
function is_ajax()
{
return isset($_SERVER['HTTP_X_REQUESTED_WITH']) && $_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest';
}
?>
Copy the following code into a file. Save the file as ajax_help… Read More