• im trying to add a Script made by me but it doesn’t work… anyone can help me? it’s like the theme don’t read the function of add.

    this same script is working in other of my websites…

    function add_my_script() {
    wp_register_script(‘menu’, home_url() . ‘/wp-content/themes/argent/js/menu.js’, array( ‘jquery’ ));
    wp_enqueue_script(‘menu’);
    }
    add_action( ‘wp_enqueue_scripts’, ‘add_my_script’ );

    this the code i use to add the script.

    help pls

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Adding JS script’ is closed to new replies.