通过将代码发送到他的手机号码来验证用户 [英] verification of user by sending code to his mobile number

查看:141
本文介绍了通过将代码发送到他的手机号码来验证用户的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望通过在注册期间向他的手机号码发送任意数量的数字代码来添加用户验证,就像在facebook中一样。告诉我如何做到这一点?

i want to add verification of user by sending any number of digit code to his mobile number during regisration just like in facebook .Tell me the way how can i do this?

推荐答案

生成一个随机数,将其存储在会话中并将其发送到用户的手机号码。一旦他输入代码(在他的手机中收到),请根据您的会话值对其进行验证。根据验证结果,系统将允许用户注册或不注册。
Generate a random number, store it in session and send it to user's mobile number. Once he enters the code (received in his mobile), validate it against your session value. Based on validation results, system will allow user to register or not.


这篇关于通过将代码发送到他的手机号码来验证用户的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆