https://discoverorg.com/wp-content/themes/discoverorg/analytics/amplitude-events.js?ver=07%3A32%3A21
1//jQuery(document).ready(function($){ 2 jQuery(window).on('load', function() { 3 4 var ampURL = "https://api2.amplitude.com/2/httpapi"; 5 var deviceId = amplitude.getInstance().options.deviceId; // existing device id 6 var path = window.location.pathname; 7 var platform = window.location.host; 8 9 /*============================================================================ 10 FOOTER 11 ============================================================================*/ 12 13 /*------------------------------------------------------ 14 DO NOT SELL MY INFO 15 ------------------------------------------------------*/ 16 17 /* AMPLITUDE EVENT ON 'Do not sell my info' CLICK 18 --------------------------------------------*/ 19 jQuery('#menu-footerlegal li:last-child a').on("click", function (event) { 20 event.preventDefault(); 21 var ampevent = { 22 "api_key": "14ff67f4fc837e2a741f025afb61859c", 23 "events": [ 24 { 25 "device_id": deviceId, 26 "event_type": "ClickedDoNotSellMyInfo", 27 "event_properties": { 28 "application": "Website", 29 "source": path, 30 "Section": "Footer", 31 } 32 }] 33 }; 34 35 jQuery.ajax({ 36 type: "POST", 37 data: JSON.stringify(ampevent), 38 url: ampURL, 39 contentType: "application/json" 40 }); 41 42 setTimeout(function(){location = jQuery('#menu-footerlegal li:last-child a').attr('href'); }, 1000); 43 }); 44 45 /*------------------------------------------------------*/ 46 47 /*============================================================================*/ 48 49 50 51 52 /*============================================================================ 53 ON SUBMIT CLICK 54 ============================================================================*/ 55 var formcomplete_flag = false; // Mark after form complete 56 57 /* AMPLITUDE EVENT SubmittedFreeTrialForm 58 --------------------------------------------*/ 59 jQuery('.wpcf7-submit').on("click", function () { 60 var currentForm; 61 if(jQuery(this).parent().parent().hasClass('wpcf7-form')) { 62 currentForm = jQuery(this).parent().parent(); 63 } 64 else { 65 currentForm = jQuery(this).parent().parent().parent(); 66 } 67 var isvalid = currentForm.valid(); 68 var errors = currentForm.find('label.error').map(function () {return jQuery(this).text().trim();}).get(); 69 var email = currentForm.find('input[name="email"]').val(); 70 71 setTimeout(function(){ 72 var formcomplete = false; 73 if(currentForm.find('input[data-zi-input-enriched="true"]').length > 0) { 74 formcomplete = true; 75 } 76 77 var outcome_type; 78 if(isvalid) { 79 // check if first submit and is a form complete form and there are empty fields 80 if (!formcomplete_flag && currentForm.find('input[name="email"]').is('[data-zi-neverbounce-status]') && currentForm.find('input[data-zi-input-enriched="false"]').length > 0) { 81 outcome_type = 'Exception'; 82 formcomplete_flag = true; 83 } 84 else { 85 outcome_type = 'Success'; 86 } 87 } 88 else { 89 outcome_type = 'Error'; 90 } 91 92 var ampevent = { 93 "api_key": "14ff67f4fc837e2a741f025afb61859c", 94 "events": [ 95 { 96 "device_id": deviceId, 97 "event_type": "SubmittedFreeTrialForm", 98 "event_properties": { 99 "application": "Website", 100 "source": path, 101 "action": "null", 102 "platformSource": platform, 103 "outcome.type": outcome_type, 104 "outcome.details": errors, 105 "email": email, 106 "autocompleted": formcomplete, 107 } 108 }] 109 }; 110 111 jQuery.ajax({ 112 type: "POST", 113 data: JSON.stringify(ampevent), 114 url: ampURL, 115 contentType: "application/json" 116 }); 117 }, 200); 118 }); 119 120 /*============================================================================*/ 121 122 }); 123//});
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.