Rev 782 | Rev 1017 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 782 | Rev 833 | ||
---|---|---|---|
Line 75... | Line 75... | ||
75 | plugin:OIDplusCaptchaPluginVtsClientChallenge.oid, |
75 | plugin:OIDplusCaptchaPluginVtsClientChallenge.oid, |
76 | action:"get_challenge" |
76 | action:"get_challenge" |
77 | }, |
77 | }, |
78 | error:function(jqXHR, textStatus, errorThrown) { |
78 | error:function(jqXHR, textStatus, errorThrown) { |
79 | if (errorThrown == "abort") return; |
79 | if (errorThrown == "abort") return; |
80 | alert("Error: "+errorThrown); //alert(_L("Error: %1",errorThrown)); |
80 | alertError("Error: "+errorThrown); //alertError(_L("Error: %1",errorThrown)); |
81 | }, |
81 | }, |
82 | success:function(data) { |
82 | success:function(data) { |
83 | if ("error" in data) { |
83 | if ("error" in data) { |
84 | alert("Error: "+data.error); //alert(_L("Error: %1",data.error)); |
84 | alertError("Error: "+data.error); //alertError(_L("Error: %1",data.error)); |
85 | } else if (data.status >= 0) { |
85 | } else if (data.status >= 0) { |
86 | OIDplusCaptchaPluginVtsClientChallenge.currentchallenge = data.challenge; |
86 | OIDplusCaptchaPluginVtsClientChallenge.currentchallenge = data.challenge; |
87 | OIDplusCaptchaPluginVtsClientChallenge.currentresponse = null; |
87 | OIDplusCaptchaPluginVtsClientChallenge.currentresponse = null; |
88 | if (autosolve) { |
88 | if (autosolve) { |
89 | // TODO: Solve using a JS Worker, so that the User UI is not slowed down... Then we also don't need the #loading spinner |
89 | // TODO: Solve using a JS Worker, so that the User UI is not slowed down... Then we also don't need the #loading spinner |
90 | OIDplusCaptchaPluginVtsClientChallenge.currentresponse = OIDplusCaptchaPluginVtsClientChallenge.captchaResponse(); |
90 | OIDplusCaptchaPluginVtsClientChallenge.currentresponse = OIDplusCaptchaPluginVtsClientChallenge.captchaResponse(); |
91 | } |
91 | } |
92 | } else { |
92 | } else { |
93 | alert("Error: "+data); //alert(_L("Error: %1",data)); |
93 | alertError("Error: "+data); //alertError(_L("Error: %1",data)); |
94 | } |
94 | } |
95 | } |
95 | } |
96 | }); |
96 | }); |
97 | 97 | ||
98 | } |
98 | } |