开发者

GET params with URI rounting/ Codeigniter

$route['ajax/get/mail'] = "mail/get_mail_by_params"; 

I am trying to request *ajax/get/mail?user_id=123&foo=bar&bar=foo*

And params it in controller:

$foo = $this->input->get('foo') 

But $_GET in ajax/get/mail variable is empty!

I suggest, that routing doesn’t supports GET parame开发者_JS百科ts. What to do?


Have you tried using the MY_Input library? http://codeigniter.com/wiki/MY_Input/

Also, I think you may need to update your URI Protocol in config.php to PATH_INFO.

$config['uri_protocol'] = "PATH_INFO";

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜