Enqueue jQuery UI Tabs In Admin Area

I normally load it as a dependancy of my plugin’s js file like so:

if ( is_admin() ) {
    //load my plugin's js
    add_action('admin_print_scripts', 'my_plugin_load_js' );

}

function my_plugin_load_js() {
    $plugin_js = WP_PLUGIN_URL . "https://wordpress.stackexchange.com/" . plugin_basename( dirname(__FILE__) ) . '/my-plugin.js';
    wp_enqueue_script('my-plugin-js', $plugin_js, array('jquery-ui-tabs'), '1.0');

}

Leave a Comment

error code: 523