【发布时间】:2014-02-21 04:12:19
【问题描述】:
slider = {
initializeWidget : function(parentNode, widgetModel)
{
var slide =
'<style type="text/css">'+
'.ui-slider {'+
'position: relative;'+
'text-align: right; '+
'width: 575px;'+
'margin:0px 0px 0px 0px'+
'}'+
'.ui-slider .ui-slider-innerBar{'+
'height:16px;'+
'width:575px;'+
'margin:3px 0px 0px 0px;'+
'background: url("desktopweb/images/slider_bg.png") no-repeat 0 0;'+
'}'+
'.ui-rangeSlider .ui-slider-handle{'+
'z-index: 10;'+
'width: 13px;'+
'height: 20px;'+
'border: 0px;'+
'background: url("desktopweb/images/tooltip.png") no-repeat ;'+
'}'+
'.ui-slider .ui-slider-bar{'+
'margin: 3px 0;'+
'background: url("desktopweb/images/slider_bg_active.png") no-repeat 0 0;'+
'background-position: left;'+
'height:20px;'+
'cursor:move;'+
'cursor:grab;'+
'cursor: -moz-grab;'+
'}'+
'.ui-slider-label{'+
'margin:0 2px 2px;'+
'background: url("desktopweb/images/calendarbackground.png") no-repeat ;'+
'background-repeat:no-repeat;'+
'bottom:0px;'+
'padding:6px 10px 15px;'+
'cursor:col-resize;'+
'}'+
'</style>'+
'<div id="slider1"></div>';
图像是通过使用图像的 url 点击它们来呈现的。 当图像 url 如上给出时,背景图像不会在 IE8 上呈现。 自定义小部件是用 JQuery 1.9.1 编写的。 请帮助解决这个问题。 提前致谢!! PS:没有显示错误,控制台中的文件夹中没有图像。
【问题讨论】:
-
为什么在 jquery 中使用样式 css 。请将其设为外部 css
-
谢谢老兄,成功了。这件事有什么解释吗?
标签: jquery css internet-explorer-8