下一个和上一个按钮在fancybox jQuery中不可见 [英] Next and previous button not visible in fancybox jquery
问题描述
jquery
$(".gallery_bg").fancybox({//displaying images
/*openEffect : 'elastic',
closeEffect : 'elastic',
'cyclic':'true',
'scrolling':'yes',
'showNavArrows':'true',
helpers : {
title : {
type : 'inside'
}
}
*/
openEffect : 'elastic',
closeEffect : 'elastic',
showNavArrows : true,
closeBtn : false,
helpers : {
title : { type : 'inside' },
buttons : {}
}
});
我已经包含了style.css
i have included the style.css
#fancybox-left-ico {
left: 20px;
}
#fancybox-right-ico {
right: 20px;
left: auto;
}
也包括我之后,我看不到下一个和上一个图标吗?
after including too i am not able to see the next and previous icon?
推荐答案
请确保文件夹中的fancybox_sprite.png
文件与jquery.fancybox.css
文件位于同一文件夹.
Be sure that the fancybox_sprite.png
file in in the same folder than the jquery.fancybox.css
file.
如果要永久显示下一个/上一个箭头,而不是仅在鼠标悬停时显示,请使用此内联css
(在加载/链接到jquery.fancybox.css
文件之后)
If you want to display the next/prev arrows permanently, not on mouse hover only, then use this inline css
(after you loaded/linked to the jquery.fancybox.css
file)
<style type="text/css">
.fancybox-next span {
left: auto;
right: 20px;
}
.fancybox-prev span {
left: 20px;
}
</style>
注意:这是针对fancybox v2.x(我假设您正在使用,因为您在脚本中使用的选项)
Note: this is for fancybox v2.x (which I assumed you are using because the options you are using in your script)
这篇关于下一个和上一个按钮在fancybox jQuery中不可见的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!