This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
$(document).on('OptinMonsterTracked', function( event, data, object ){ | |
console.log(data.optin + '-' + data.type + " successfully tracked"); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
//Snag the URL of the iframe so we can use it later | |
var url = $('.optin_custom_html_applied iframe').attr('src'); | |
$(document).on('OptinMonsterOnClose', function( event, data, object){ | |
//Assign the iframe's src to null, which kills the video | |
$('.optin_custom_html_applied iframe').attr('src', ''); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready(function($){ | |
$(document).on('OptinMonsterBeforeOptin', function(event, data, object){ | |
// Grab the email address submitted by the user. | |
var email = $('#om-' + data.optin).find('input[type="email"]').val(); | |
// Test to ensure it is a proper email. Otherwise, redirect to another page. | |
if ( /@yahoo.com$/.test(email) || /@gmail.com$/.test(email) || /@hotmail.com$/.test(email) || /@googlemail.com$/.test(email) || /@live.com$/.test(email) || /@aol.com$/.test(email) || /@outlook.com$/.test(email) || /@comcast.net$/.test(email) || /@inbox.com$/.test(email) || /@hushmail.com$/.test(email) || /@lycos.com$/.test(email) || /@zoho.com$/.test(email) || /@gmx.com$/.test(email) ) { | |
window[data.optin_js].optin = function(){ | |
return window.location.href = 'http://optinmonster.com/'; | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
$(document).on('OptinMonsterBeforeClose', function( event, data, object ){ | |
var url = "http://optinmonster.com"; | |
$(location).attr('href',url); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
$(document).on('OptinMonsterPositionOptin', function( event, data, object ){ | |
$('#om-canvas-whiteboard-optin').dragon(); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
//Snag the URL of the iframe so we can use it later | |
var url = $('.optin_custom_html_applied iframe').attr('src'); | |
$(document).on('OptinMonsterOnShow', function( event, data, object){ | |
//Below we remove the URL to stop the video from playing, here we add it back in | |
$('.optin_custom_html_applied iframe').attr('src', url); | |
}); | |
$(document).on('OptinMonsterOnClose', function( event, data, object){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* --- CSS to position the video overlay --- */ | |
#overlay { | |
position: fixed; | |
left: 0; | |
top: -90px; | |
bottom: 0; | |
right: 0; | |
width: 100%; | |
height: 500%; | |
background: #000; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
$(document).on('OptinMonsterLoaded', function( event, data, object ){ | |
console.log("Congratulations! The " + data.optin + '-' + data.type + " optin has been successfully loaded."); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
$(document).on('OptinMonsterManualOptinError', function( event, data, object ){ | |
console.log("Oops! There was a problem loading the " + data.optin + '-' + data.type + " manual-trigger optin on this page."); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).ready( function($){ | |
$(document).on('OptinMonsterManualOptinSuccess', function( event, data, object ){ | |
console.log("Congratulations! The " + data.optin + '-' + data.type + " manual-trigger optin has been successfully loaded."); | |
}); | |
}); |