我有一个滑出式标签,它在左侧完美运行,但是当我更改设置以将其定位在右侧时 - 标签图像消失并且内容保持打开状态。
在选项卡下滑出 DIV 我有这个 js
$('.slide-out-div').tabSlideOut({
tabHandle: '.handle', //class of the element that will be your tab
pathToTabImage: 'images/getstarted.gif', //path to the image for the tab *required*
imageHeight: '139px', //height of tab image *required*
imageWidth: '27px', //width of tab image *required*
tabLocation: 'right', //side of screen where tab lives, top, right, bottom, or left
speed: 300, //speed of animation
action: 'click', //options: 'click' or 'hover', action to trigger animation
topPos: '0px', //position from the top
fixedPosition: false //options: true makes it stick(fixed position) on scroll
});
然后有一个js文件有这些设置
(function($){
$.fn.tabSlideOut = function(callerSettings) {
var settings = $.extend({
tabHandle: '.handle',
speed: 300,
action: 'click',
tabLocation: 'left',
topPos: '200px',
leftPos: '20px',
fixedPosition: false,
positioning: 'absolute',
pathToTabImage: null,
imageHeight: null,
imageWidth: null,
onLoadSlideOut: false
}, callerSettings||{});
我的 CSS
.slide-out-div {
padding: 12px;
width: 220px;
height: 87px;
border: 2px inset #1e5e70;
font-family: Arial, Helvetica, sans-serif;
background-color: #eefbfe;
background-image: url(../images/stripe.png);
background-repeat: repeat;
z-index:999;
}
我的网站是http://www.pagetree.co.uk
谢谢!