• Hi
    I could successfully load a script in a theme, that i built from scratch.
    Here is the procedure in functions.php:

    //scripts for animation//
    function anim_scripts() {
    
        if( is_page(array('28','45'))) { //
    			wp_enqueue_script( // Load up my script
                'bganim',
                get_stylesheet_directory_uri() . '/js/bganim.js',
                array('jquery')
            ); // End of enqueue
    
        } // End is
    } //
    add_action('wp_enqueue_scripts', 'anim_scripts');

    When i do the same thing in a child of 2013, i get an error in the console: something like ?$ is not a function?.

    Why is that?
    Does anyone have an idea, why this error comes up with the child of 2013 and not with my own theme?

    Thanks for your time and interest.

    regards
    theo

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