CSS replace like for Event calendar

Home Forums Calendar Products Community Events CSS replace like for Event calendar

Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • #73127
    mastafu
    Participant

    Can we replace main .css file with function like for Calendar Events and widgets ?

    I used this but with no luck …
    function replace_tribe_events_community_events_stylesheet() {
    $styleUrl = get_bloginfo(‘template_url’) . ‘/custom-events-community.css’;
    return $styleUrl;
    }
    add_filter(‘tribe_community_events_stylesheet_url’, ‘replace_tribe_events_community_events_stylesheet’);

    #73511
    Julie Kuehl
    Participant

    Hi mastafu,

    I’m not sure I understand what you are trying to accomplish. But if you’re trying to create a custom css file, you can find information on how to do that in our Themer’s Guide in the Customizing Styles section where it shows you how (https://theeventscalendar.com/support/documentation/events-calendar-themers-guide/#customizingstyles). You’ll probably want to set up a custom tribe-events.css file to do that.

    — Julie

    #73541
    mastafu
    Participant

    Julie, I have used your method for Events and Events Pro. What I am asking is, there a same mechanism for Community Events.

    #73716
    Julie Kuehl
    Participant

    Hey mastafu,

    Ah, my bad. Does this help? https://theeventscalendar.com/adding-custom-css-to-your-community-events-pages/

    — Julie

    #73740
    mastafu
    Participant

    I think this adds extra styles, I asking for override feature just like in Event Calendar and Pro. There is function to change file, from plugin dir to your themes dir.

    #73912
    Julie Kuehl
    Participant

    mastafu,

    Yeah, you should be able to do an override. We had a similar thread earlier: https://theeventscalendar.com/support/forums/topic/how-do-you-customize-the-form/. The last comment by Casey should get you going in the right direction.

    Happy coding!

    — Julie

    #73950
    mastafu
    Participant

    The last comment is about views override. I want to know how to do this (but for community plugin)

    Replacing Default Stylesheets
    If you’d like to replace the default stylesheets offered by The Events Calendar, you can use any of the filters we have provided to do so:

    tribe_events_stylesheet_url (The Events Calendar core styles)
    tribe_events_pro_stylesheet_url (The Events Calendar Pro styles)
    tribe_events_pro_widget_calendar_stylesheet_url (The Events Calendar calendar widget styles)
    For example:

    Let’s say you want to replace the custom core and PRO stylesheets offered by the plugin and load your theme’s own stylesheets called custom-events-stylesheet.csts and custom-events-pro-stylesheet.css respectively. You can use the aforementioned filters like this:

    function replace_tribe_events_calendar_stylesheet() {
    $styleUrl = get_bloginfo(‘template_url’) . ‘/custom-events-stylesheet.css’;
    return $styleUrl;
    }
    add_filter(‘tribe_events_stylesheet_url’, ‘replace_tribe_events_calendar_stylesheet’);

    function replace_tribe_events_calendar_pro_stylesheet() {
    $styleUrl = get_bloginfo(‘template_url’) . ‘/custom-events-pro-stylesheet.css’;
    return $styleUrl;
    }
    add_filter(‘tribe_events_pro_stylesheet_url’, ‘replace_tribe_events_calendar_pro_stylesheet’);

    #74158
    Rob
    Member

    Hey Mastafu: what Julie pointed to above is probably the closest we’ve got to offer on this. Unless I’m misunderstood, doesn’t the thread shared show you how to accomplish exactly what you’re going for here?

    #74369
    mastafu
    Participant

    To my understanding You show me a whato add extra css and I want to change to which css file community points. Just like in Events.

    That way I can copy all Community styles to my themes folder and modify it wihtout nasty overrides. And be sure that You will not owerrite it with update.

    #74697
    Rob
    Member

    Hey mastafu. Thanks for the follow-up here. I’ve got Casey, our resident Community Events expert, on deck to reply to you in full tomorrow on this. Thanks for your patience thus far.

    #74761
    Casey
    Participant

    Mastafu,
    Unfortunately we don’t have a filter for that in Community events, but you should be able to do the following by dequeueing the Community styles and enqueueing your own styles. Just paste this code snippet into your theme’s functions.php file and it should get you started in the right direction: https://gist.github.com/ckpicker/7321714

    Let me know if that does the trick! Thanks!

    #79318
    Casey
    Participant

    Mastafu,
    Are you still having problems with this? If so, just take a look at my previous thread and let me know if that worked for you. If not, just let me know and I’ll close out this thread.

    Thanks!

    #84900
    Casey
    Participant

    Mastafu,
    Just wanted to follow up with you on this and see if you were able to try out my suggestion above. Let me know if this is still an issue for you. Thanks!

    #84924
    mastafu
    Participant

    I have managed to help myself, and I am not drilling the topic 🙂

    #84928
    Casey
    Participant

    Thanks for confirming that this got you sorted. Since it sounds like you’re all set here, I’m going to mark this thread “Answered” and close it out.

    By the way, if you have a minute or two, we would love it if you’d write a few words for us here: http://wordpress.org/support/view/plugin-reviews/the-events-calendar?filter=5

    Thanks in advance. 🙂

    Cheers,
    Casey

Viewing 15 posts - 1 through 15 (of 15 total)
  • The topic ‘CSS replace like for Event calendar’ is closed to new replies.