This commit is contained in:
James Campos 2011-08-06 10:37:37 -07:00
parent 9adfa5f866
commit 4bb6b4cf88
2 changed files with 8 additions and 7 deletions

View File

@ -1230,16 +1230,16 @@
qr = {
init: function() {
var iframe;
g.callbacks.push(qr.node);
iframe = $.el('iframe', {
name: 'iframe',
hidden: true
});
$.append(d.body, iframe);
g.callbacks.push(qr.node);
$.bind(window, 'message', qr.message);
$('#recaptcha_response_field').id = '';
$.bind($('#recaptcha_challenge_field_holder'), 'DOMNodeInserted', qr.captchaNode);
return qr.captcha = [];
qr.captcha = [];
return $('#recaptcha_response_field').id = '';
},
attach: function() {
var file, files;

View File

@ -969,20 +969,21 @@ qr =
# remove file
# error handling
# persistent captcha
# code review
init: ->
g.callbacks.push qr.node
$.bind window, 'message', qr.message
$.bind $('#recaptcha_challenge_field_holder'), 'DOMNodeInserted', qr.captchaNode
qr.captcha = []
iframe = $.el 'iframe',
name: 'iframe'
hidden: true
$.append d.body, iframe
$.bind window, 'message', qr.message
#hack - nuke id so it doesn't grab focus when reloading
$('#recaptcha_response_field').id = ''
$.bind $('#recaptcha_challenge_field_holder'), 'DOMNodeInserted', qr.captchaNode
qr.captcha = []
attach: ->
$('#auto', qr.el).checked = true
file = $.el 'input', type: 'file', name: 'upfile'