I have the following code in my plugin main file :
function my_function() {
?>
<script type="text/javascript">
jQuery(function () {
alert('jQuery');
});
</script>
<?php
}
add_action("wp_footer", "my_function");
My website does have jQuery loaded and operational (lots of features on my page use it and they work). Yet this alert() doesn't work. Why is that ?