Created
July 27, 2018 17:28
-
-
Save brianaohern/471f05e5507c97175bb048363affec06 to your computer and use it in GitHub Desktop.
WordPress JavaScript Example
This file contains 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
<?php wp_footer(); ?> | |
// Your JavaScript goes below | |
<script type="text/javascript"> | |
// This example calls om.Campaign.init runs once the campaign is initialized | |
document.addEventListener('om.Campaign.init', function(event) { | |
// This event is passed the Campaign object | |
console.log(event.detail.Campaign); | |
// Additional JavaScript here | |
} ); | |
</script> | |
</body> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment