JQuery UI datepicker: How to color the sundays in red?
source link: https://www.codesd.com/item/jquery-ui-datepicker-how-to-color-the-sundays-in-red.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
JQuery UI datepicker: How to color the sundays in red?
i need sundays to highlight in red.
I know that there is a class called ui-datepicker-week-end
.
My problem is, that the other classes (ui-widget-content
and ui-state-default
) overwrite the red color of ui-datepicker-week-end
, even if set !important
.
The only thing that is colored are the weekend days in the headline of the calendar.
You can style the anchors that are descendants of the .ui-datepicker-week-end
elements, and set their background-image
property to none
when adding the background color. This gives good results without you having to use !important
:
.ui-datepicker-week-end a {
background-image: none;
background-color: red;
}
EDIT: If you want to set the color
property instead of background-color
, you will indeed have to use !important
:
.ui-datepicker-week-end a {
color: red !important;
}
You can see the results in this fiddle.
Related Articles
JQuery UI DatePicker: How to set the value on an arbitrary string?
JQuery UI Datepicker - How to delete the & ldquo; Done & rdquo; button
jQuery UI datepicker: How to wrap the datepicker in a new division?
jquery datepicker how to color the dataset?
How to color the foreground text of Linux terminal and background
How to color the dot density in the scatter diagram using R
How to identify the performance of Redis / bottlenecks
jQuery UI Datepicker: How to add clickable events to specific dates?
jQuery UI Datepicker - How to edit Datepicker HTML
Android Datepicker - How to pass the date of the activity to the fragment
How to color the static control background in the select-for-folder dialog box?
jQuery dynamic elements - how to delete the item and save the event data?
With Jquery ui draggable, how to change the return on stop?
How to color the cell according to the 2D coordinate and its value? New Excel function
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK