jQuery datepicker next / prev图片 [英] jQuery datepicker next/prev images
问题描述
我尝试为下一个/上个月按钮设置自定义图像。我尝试使用datepicker的prevText / nextText选项将span与我自己的css类定义,但它将其添加到链接标题,因此它是无效的HTML。
I'm trying to set custom images for next / prev month buttons. I tried to use prevText / nextText options of datepicker to put span with my own css class definition, but it adds it to links title, so it's invalid HTML.
't想更改.ui-icon-circle-triangle-w和.ui-widget-header .ui-icon规则在jQuery UI CSS ...我只是想添加/更改的类, of a。
I don't want to change .ui-icon-circle-triangle-w and .ui-widget-header .ui-icon rules in jQuery UI CSS...i just want to add / change the class for rendered span element that is inside of a.
推荐答案
在自定义ID或类中包含日期选择器,然后更改.ui-icon类的背景:
Contain your datepicker in a custom ID or class, then change the background on the .ui-icon class:
#my-calendar-id .ui-datepicker-next .ui-icon {background:url('my_image'); }
当使用jQuery UI CSS堆栈时,特定性是关键。
Specificity is key when working with the jQuery UI CSS stack.
这篇关于jQuery datepicker next / prev图片的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!