We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
先在captcha 的索引是通过rucaptcha_sesion_key_key 来存在session 里面的。但是如果是无状态的API 接口的话(移动端),就不太好用了。
像这样把captcha 在存储中的key 返回,就可以支持不用cookie 的API了
def new_generate_rucaptcha res = RuCaptcha.generate() session_val = { code: res[0], time: Time.now.to_i } RuCaptcha.cache.write(rucaptcha_sesion_key_key, session_val, expires_in: RuCaptcha.config.expires_in) opts = { disposition: 'inline', type: 'image/gif', filename: rucaptcha_sesion_key_key } send_data res[1], opts end
The text was updated successfully, but these errors were encountered:
No branches or pull requests
先在captcha 的索引是通过rucaptcha_sesion_key_key 来存在session 里面的。但是如果是无状态的API 接口的话(移动端),就不太好用了。
像这样把captcha 在存储中的key 返回,就可以支持不用cookie 的API了
The text was updated successfully, but these errors were encountered: