我正在为我的女朋友开发一个模特网站,她想要一个大型幻灯片作为网站的背景。为此,我使用了 JonDesign Gallery,它可以很好地用于此目的,而且重量相对较轻。
现在,对于联系表单,我想使用 Lightbox/Slimbox 样式。Slimbox 与 Mootools 配合使用,JD Gallery 也使用该工具。不幸的是,Slimbox 似乎与 JD Gallery 冲突,我不知道为什么。我检查了 CSS 是否存在冲突,但没有元素 ID 或分类两次。我查看了代码,无法立即发现冲突。我确定我错过了什么。我无法弄清楚,因为我对 JavaScript 没有太多经验,更不用说 Mootools 或 Slimbox。
这是我的(相关)代码。
头
<link rel="stylesheet" href="css/layout.css" type="text/css" media="screen" charset="utf-8" />
<link rel="stylesheet" href="css/jd.gallery.css" type="text/css" media="screen" charset="utf-8" />
<link rel="stylesheet" href="css/slimbox.css" type="text/css" media="screen" />
<script type="text/javascript" src="scripts/mootools.js"></script>
<script src="scripts/mootools-1.2.1-core-yc.js" type="text/javascript"></script>
<script src="scripts/mootools-1.2-more.js" type="text/javascript"></script>
<script src="scripts/jd.gallery.js" type="text/javascript"></script>
<script src="scripts/jd.gallery.transitions.js" type="text/javascript"></script>
<script type="text/javascript" src="scripts/slimbox.js"></script>
身体
<script type="text/javascript">
function startGallery() {
var myGallery = new gallery($('myGallery'), {
timed: true,
showArrows: false,
showCarousel: false,
delay: 6000,
embedLinks: false,
showInfopane: false,
});
}
window.addEvent('domready', startGallery);
</script>
<div id="myGalleryBox">
<a href="contact.php" rel="lightbox" class="menu">Contact her</a>
</p>
</div>
<div class="content" style="z-index:1;">
<div id="myGallery">
<div class="imageElement">
<h3>Item 2 Title</h3>
<p>Item 2 Description</p>
<a href="#" title="open image" class="open"></a>
<img src="images/pic1.jpg" class="full" />
</div>
</div>
</div>`
据我所知,冲突在以下几行之间:
<script type="text/javascript" src="scripts/mootools.js"></script>
和
<script src="scripts/mootools-1.2.1-core-yc.js" type="text/javascript"></script>
<script src="scripts/mootools-1.2-more.js" type="text/javascript"></script>
在头上。
我正在使用来自JD Gallery和SlimBox的未修改代码。任何帮助将非常感激!