Support » Plugin: WP FullCalendar » Colours not used on all events

Viewing 14 replies - 1 through 14 (of 14 total)
  • Beee


    I just came to the conlusion that it might be because each event has multiple categories.

    My directory structure is as follows:
    – Classic luge
    – Drift trike
    – Gravity bike
    – Inline
    – Standup
    – Street luge
    Event type
    – Freeride (#ceeecc)
    – Misc
    – Race (#e5454a)

    Can it be that the colour is overwritten by a category which colour isn’t defined (by me) ? And if so, how to prevent it ?

    I only want to colour the event types, not the disciplines.

    Plugin Support angelo_nwl


    did you have multiple category in one event?



    one for discipline, one for event type



    can you maybe tell me how the categories are identified uniquely ?

    I have a custom css template which is loaded last in the header, so anything I define there overwrites any previous values in css.



    I just found out the colours are hardcoded.

    I see two colours, because there is only 1 category colour defined (of 3 used categories, but since 2 are white, I think the code only shows white only once.)

    I see this being used.

    <div class="fc-event-inner fc-event-skin" style="background-color: rgb(229, 69, 74); border-color: rgb(229, 69, 74); color: rgb(255, 255, 255);">

    Isn’t it an idea to give each item a unique class like post_class() ?
    Instead of just “fc-event-inner fc-event-skin” because this doesn’t identify an event uniquely.

    In my case this event would then have 3 categories;
    1) category-slug1
    2) category-slug2
    3) category-slug3

    <div class="fc-event-inner fc-event-skin category-slug1 category-slug2 category-slug3"

    These can all be identified uniquely through a stylesheet.

    I think it’s a good idea to include tags here as well.

    The other idea is to only define a colour when the value is set. So upon initialization, the category (bg) colour should read none, instead of white. If the value is none, it shouldn’t be hardcoded.

    Anyway that’s my 0,02…

    If anyone knows a way to hook in a custom piece of code for it, I’m interested.



    I just posted a similar question here.

    I agree that your suggestions would help, either by adding a class for the category, or defining a color only when the value is set.

    So far I haven’t figured out a way to precisely set colors when multiple categories are used.

    Even when only one category is used, it appears that the parent category overrides the child, which seems backwards to what I want.

    parent-cat (RED)
      child-cat (BLUE)
    2parent-cat (black)
      2child-cat (white)

    If the an event has both ‘parent-cat’ and ‘child-cat’ assigned its color will be RED.

    However if it has parent-cat, child-cat and 2child-cat assigned it will be white.

    EDIT: my second line of logic seems to be off. The color assignment is not consistent when a second child category is used. Maybe it is alphabetical or in order of category creation?

    EDIT: It appears as though the hierarchy of category colors is determined by the alphabetical name of the category.


    boats (black)
        big (white)
        small (blue)
    yachts (green)
        yachts-small (pink)

    If ‘big’ is assigned the color will always be white, no matter the other categories assigned.

    The only way to make the category ‘pink’ color to show up is if ‘yachts-small’ is the only category assigned.



    Yeah, i think so, but I don’t want that…

    each event needs a type; race, freeride, misc
    and it needs one or more disciplines.

    I’m only looking to colour the disciplines for now.



    Agreed, I would like full CSS control of the colors.

    I figured out a way to work around it for now. It’s definitely not optimal, but it works.

    I created an additional category for each color that I want to use. I set the color and started the title with a number to ensure that it will always be first alphabetically.


    Then assign those categories to events.

    Then I used this snippit in functions.php to exclude the new categories from the ‘All Event Categories’ dropdown list.

    // if we need to exclude things from the dropdown category menu on the calendar page
    function em_wpfullcalendar_category_label($taxonomy_args,$taxonomy){
     if ( $taxonomy->name == 'event-categories'){
      $taxonomy_args['exclude'] = '90,55,109,24,114'; // categories to exclude
     return $taxonomy_args;

    There are a few other places to exclude the color categories as well. `[fullcalendar category=”-190,-55,-109,-24,-114″]
    [events_list category=”-90,-55,-109,-24,-114″]`



    I appreciate the time you took to create a solution but I find this too much hassle, the more since this is too much work for just adding a simple colour, with an option partially there…

    imo it needs some tweaking

    I just hope Marcus has read this topic…

    I submitted a feature request on this, asking for more fine-grained category color handling.

    did you get an answer and if so what was it ?

    Nothing conclusive, yet.

    Need a solution too for that.

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Colours not used on all events’ is closed to new replies.