PageSourceSearch

https://ipi.media/wp-content/themes/ipi-theme/assets/js/simple-mailchimp-form.js

js ipi.media collected 2026-09-24 07:04:28 UTC 1,028 bytes, 31 lines download raw bytes

1jQuery(function($) {
2  $('form.simple-mailchimp-form').on('submit', function(e) {
3    e.preventDefault();
4
5    var $form = $(this);
6    var email = $form.find('input[name="email"]').val();
7    var list_id = $form.find('input[name="list_id"]').val();
8
9    $.post(SimpleMailchimpForm.ajax_url, {
10      action: 'simple_mailchimp_subscribe',
11      nonce: SimpleMailchimpForm.nonce,
12      email: email,
13      list_id: list_id
14    }, function(response) {
15      $form.find('.alert').remove(); // Remove previous alerts
16
17      var status = response.success ? response.data.status : response.data.status;
18      var message = response.success ? response.data.message : response.data.message;
19      var alertClass = 'alert-danger';
20
21      if (status === 'success') {
22        alertClass = 'alert-success';
23      } else if (status === 'warning') {
24        alertClass = 'alert-warning';
25      }
26
27      var alert = $('<div class="alert ' + alertClass + ' mt-3" role="alert">' + message + '</div>');
28      $form.append(alert);
29    });
30  });
31});

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.