Questions about IOS mobile phone verification code

Source: Internet
Author: User
For IOS mobile phone verification code, I recently got an ios & nbsp; app & nbsp; Project. I have a question: Ask the mobile phone Terminal & nbsp; after entering the user's mobile phone number, call the backend verification code Sender program, the backend php sends a verification code text message to the user's mobile phone. how can I set the validity period of the verification code (120 s )? Use session_start? Session_start is not supported and the output data is empty. Or where did I get it wrong? why is the verification code on IOS?
I am working on an ios app project recently. I have a question.
After the mobile phone end enters the user's mobile phone number, it calls the backend verification code Sender program. The backend php sends a verification code text message to the user's mobile phone,
Excuse me:
How do I set the SMS verification code validity period (120 s )? Use session_start? Session_start is not supported and the output data is empty.
Or where did I make a mistake? the webpage debugging session records the information.
Please help. Thank you.


------ Solution ----------------------
1. use redis expire to set 120 s
2. submit the verification code to the background mobile phone number and verification code at the same time without session storage verification code
------ Solution ----------------------
It can be stored in the database and then called for processing.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.