我有一个项目,需要为用户生成唯一的 5 位数字母数字 ID。我怎样才能使用 codeigniter 实现这一点!?
thanks
字符串助手中有一个名为 random_string 的函数。
$this->load->helper('string');
echo random_string('alnum',5);
Details http://codeigniter.com/user_guide/helpers/string_helper.html
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)