racekatten

Forum Replies Created

Viewing 1 post (of 1 total)
  • Author
    Posts
  • in reply to: Load stylesheet for home-build widget #1605660
    racekatten
    Participant

    No, I still cannot make it work.

    I just want to load your stylesheet:
    http://<domain>/wp/content/plugins/the-events-calendar/src/resources/css/tribe-events-full.min.css

    When my widget is active:
    tribe-events-list-rk-widget

    And I’m not really sure where to place tribe_asset()
    I have tried inside the class for my widget.

    Before I was using:
    function my_loadStyle() {
    if ( is_active_widget( false, false, ‘tribe-events-list-rk-widget’ ) ) {
    Tribe__Events__Template_Factory::asset_package( ‘events-css’ );
    }
    }
    add_action( ‘wp_enqueue_scripts’, ‘my_loadStyle’ );
    Which I could place where ever I wanted in my functions.php

Viewing 1 post (of 1 total)