PageSourceSearch

https://www.publipresse.fr/plugins/publipresse/forms/assets/js/recaptcha.js

js publipresse.fr collected 2026-10-04 09:19:12 UTC 1,097 bytes, 36 lines download raw bytes

1var onloadCallback = function() {
2    var recaptchas = document.querySelectorAll('.g-recaptcha');
3
4    recaptchas.forEach(function(el) {
5        if(el.dataset.size == 'invisible') {
6            const form = el.closest('form');
7            const alias = form.dataset.request.split('::')[0];
8            const widgetId = grecaptcha.render(el, {
9                callback: function(token) {
10                    oc.request(form, (alias+'::onFormSubmit'), {
11                        complete: function(data) {
12                            resetReCaptcha(widgetId);
13                        }
14                    });
15                }
16            });
17            submitReCaptcha(form, widgetId);
18        } else {
19            grecaptcha.render(el);
20        }
21    });
22}
23
24function resetReCaptcha(widgetId) {
25    grecaptcha.reset(widgetId);
26}
27
28function submitReCaptcha(form, widgetId) {
29    const submit = form.querySelector('[type="submit"]');
30    if(submit) {
31        submit.addEventListener('click', function(e) {
32            e.preventDefault();
33            grecaptcha.execute(widgetId);
34        });
35    }
36}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.