OrionTraveler2
Membre-
OrionTraveler2 a publié un message Il y a 2 semaines
I wrote a jQuery script for my WordPress plugin, and it looks like this:
$(function() { // jQuery code here });
Even though I make sure that jQuery is loaded on the page, I keep getting the following error in the browser console:
TypeError: $ is not a...
-
Make sure your script is enqueued correctly in WordPress, with jQuery declared as a dependency. Use the following PHP code:
php
Copy code
function enqueue_my_script() {
wp_enqueue_script(
‘my-custom-script’, // Handle name for your… En savoir plus1
-