How can I change the specefic event background color in JQuery FullCalendar
How can I change the event background color while on rendering events on calendar. How can I change specific event background color in javascript, 开发者_开发知识库I have assigned the event with id.
would make sure the event has a specific "className" and then color it through css. more info here: http://arshaw.com/fullcalendar/docs/event_rendering/Colors/
you may alter the "fc-event
" values in the fullcalendar.css
to change the default event background,
or you can add a new css class as follows:
.newtype,
.fc-agenda .newtype.fc-event-time,
.newtype a {
border-style: solid;
border-color: #6da; /* default BORDER color (probably the same as background-color) */
background-color: #6da; /* #36c; default BACKGROUND color */
color: #fff; /* default TEXT color */
}
and specify it to the event throught className
:
event.className="newtype";
p.s. you need get the event object by function .fullCalendar( 'clientEvents', event_id)
first
Good luck
精彩评论