Detect when Javascript is disabled on the page and use the noscript captcha.
This commit is contained in:
parent
e028273eed
commit
274190e6bb
@ -7,7 +7,9 @@ QR =
|
||||
@db = new DataBoard 'yourPosts'
|
||||
@posts = []
|
||||
|
||||
@captcha = Captcha[if Conf['Force Noscript Captcha'] then 'noscript' else 'v2']
|
||||
$.globalEval 'document.documentElement.dataset.jsEnabled = true;'
|
||||
noscript = Conf['Force Noscript Captcha'] or !doc.dataset.jsEnabled
|
||||
@captcha = Captcha[if noscript then 'noscript' else 'v2']
|
||||
|
||||
if Conf['QR Shortcut']
|
||||
sc = $.el 'a',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user