Set default (no category) color for calendar view

WordPress Event Management, Calendars & Registration Forums General Question Set default (no category) color for calendar view

This topic contains 2 replies, has 2 voices, and was last updated by  oliowork 9 years, 5 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #19457

    Hello,

    I have implemented the hook you describe here http://wp-event-organiser.com/forums/topic/change-event-color/

    Perhaps things have changed since 2013? I have the following in functions.php

    function eo_assign_default_event_color( $color, $event_id ){
        if( empty( $color ) ){
            $color = '#A34F16'; //rust
        } 
        return $color;
    }
    
    add_filter( 'eventorganiser_event_color', 'eo_assign_default_event_color', 10, 2 );
    

    But I still get the calendar output with inline style background-color: rgb(33, 117, 155).

    Running latest EO Pro and latest WordPress.

    Is there a new way to handle setting a default color?

    Thank you.

    oliowork
    #19461

    Hi oliowork,

    Have you tried editing an event? The calendar is cached so any changes its appearance made using a filter might not take immediate effect.

    Updating an event should clear the cache.

    Stephen Harris
    #19476

    Thank you! That did indeed make the change show up.

    Much obliged!

    oliowork
Viewing 3 posts - 1 through 3 (of 3 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.