PageSourceSearch

https://waseala.net/waseala/js/contact.js

js waseala.net collected 2026-10-02 02:03:02 UTC 2,564 bytes, 56 lines download raw bytes

1$(function () {
2
3    window.verifyRecaptchaCallback = function (response) {
4        $('input[data-recaptcha]').val(response).trigger('change');
5    }
6
7    window.expiredRecaptchaCallback = function () {
8        $('input[data-recaptcha]').val("").trigger('change');
9    }
10
11    $('#contact-us-form').validator();
12
13    $('#contact-us-form').on('submit', function (e) {
14        if (!e.isDefaultPrevented()) {
15            var url = "https://j11vo0yw1k.execute-api.us-east-1.amazonaws.com/prod/api";
16            var jsonMsg = JSON.stringify({
17                surname: $("#contact-us-form input[name='surname']").val(),
18                name: $("#contact-us-form input[name='name']").val(),
19                email: $("#contact-us-form input[name='email']").val(),
20                phone: $("#contact-us-form input[name='phone']").val(),
21                message: $("#contact-us-form textarea[name='message']").val(),
22                'g-recaptcha-response': $("#contact-us-form textarea[name='g-recaptcha-response']").val()
23            });
24
25            $.ajax({
26                type: "POST",
27                url: url,
28                // The key needs to match your method's input parameter (case-sensitive).
29                data: jsonMsg,
30                contentType: "application/json; charset=utf-8",
31                dataType: "json",
32                success: function (data) {
33                    var messageText = "Thanks for contacting us, we will get back to you soon.";
34
35                    var alertBox = '<div class="alert alert-success alert-dismissable"><button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button>' + messageText + '</div>';
36                    if (messageText) {
37                        $('#contact-us-form').find('.messages').html(alertBox);
38                        $('#contact-us-form')[0].reset();
39                        grecaptcha.reset();
40                    }
41                },
42                error: function (errMsg) {
43                    var messageText = errMsg.message;
44
45                    var alertBox = '<div class="alert alert-danger alert-dismissable"><button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button>' + messageText + '</div>';
46                    if (messageText) {
47                        $('#contact-us-form').find('.messages').html(alertBox);
48                        $('#contact-us-form')[0].reset();
49                        grecaptcha.reset();
50                    }
51                }
52            });
53            return false;
54        }
55    });
56});

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.