在 jQuery UI 对话框确认框中使用验证码
我有一个 JQuery UI 对话框确认框,我需要“额外确定”用户在单击“确认”时确实是这么想的,所以我想我想使用验证码来捕获此确认。基本上,禁用弹出窗口中的“确认”按钮,直到输入的文本与验证码图像匹配。
关于如何做到这一点的任何想法,或者甚至是更好的方法来做到这一点,而不必求助于愚蠢的第二个“你真的真的真的确定吗?”弹出窗口?
I have a JQuery UI Dialog confirmation box that I need to make "extra sure" that the user really means it when they click "Confirm", so I think I want to use a CAPTCHA to capture this confirmation. Basically, disable the "Confirm" button in the popup until the entered text matches the CAPTCHA image.
Any ideas on how to do this, or even a better way to do this without resorting to a silly second "Are you really really really sure?" popup?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果您只想在客户端解析验证码,那么它们很容易被绕过。不要相信浏览器。
所以你确实想在服务器上进行检查。如何包含它取决于您选择使用的验证码。
如果不是关于验证码,而是让用户思考“正确的选择”:我所做的是给用户思考时间:仅在一定时间后启用提交按钮。但显示“思考计时器”倒计时。 (顺便说一句:用户讨厌它,但至少他们考虑自己的选择,而不是如何阅读验证码)。
If you want to resolve a CAPTCHA only on the client side, they are very easily bypassed. Do not trust a browser.
So you really want to do the checking on the server. How to include it, depends on the captcha you choose to use.
If it is not a about a captcha, but making users think about "the right choice": What I did is giving users think time: Enabling the submit button only after a certain time. But displaying a "think timer" countdown. (btw: users hate it, but at least they think about their choice and not how to read a captcha).
我认为实施验证码会给您带来额外的工作(并且会给您的用户带来更多烦恼)。也许最好直接抛出:
一旦他们在 UI 表单上单击“确认”。
I think implementing a captcha will be extra work for you (and more annoyance for your users). Perhaps it's better to just throw:
Once they click confirm on the UI form.