Access our premium support and let us know your problems, we will help you solve them.

0
No products in the cart.

Forum Replies Created

Viewing 1 post (of 1 total)
  • Author
    Posts
  • in reply to: How To Include CSS and jQuery in my WordPress plugin? #9998
    blankhardik-kalathiya
    Participant

    You can use the following function to enqueue script or style from plugin.

    function my_enqueued_assets() {
        wp_enqueue_script('my-js-file', plugin_dir_url(__FILE__) . '/js/script.js', '', time());
        wp_enqueue_style('my-css-file', plugin_dir_url(__FILE__) . '/css/style.css', '', time());
    }
    add_action('wp_enqueue_scripts', 'my_enqueued_assets');
    
Viewing 1 post (of 1 total)