所以我刚刚使用 twitter-bootstrap 模板完成了一个网站,偶然发现了一个小问题。在本地运行页面时,一切正常,但是将页面上传到虚拟服务器后,prettyPhoto拒绝显示网站上一半的图片,说:请求的URL /img/gallery/gallery-04.jpg is not在这台服务器上找到。
正如我所说,当我在本地运行页面时,一切正常。我检查并仔细检查了所有必要的脚本,一切似乎都井井有条。无论如何,这是我的代码:
<div class="span6 YDCOZA usability packaging">
<div class="single-item">
<div class="img-box">
<img src="img/gallery/gallery-04.jpg" alt="Alt Text" width="960"; height="720"; >
<div class="single-navigation">
<a class="fullimage" rel="prettyPhoto" href="img/gallery/gallery-04.jpg">
<div class="full-image">
</div>
</a>
</div>
<!-- .single-navigation -->
</div>
<!-- .img-box -->
</div>
<!-- .single-item -->
</div>
<!-- Footer Scripts -->
<script src="js/libs/bootstrap/bootstrap.min.js"></script>
<script src="js/jquery.easing.1.3.js"></script>
<script src="js/jquery.flexslider-min.js"></script>
<script src="js/jquery.hoverIntent.minified.js"></script>
<script src="js/plugins.js"></script>
<script src="js/jquery.prettyPhoto.js"></script>
<script src="js/jquery.isotope.min.js"></script>
<script src="js/script.js"></script>
<!-- Header Scripts -->
<link rel="stylesheet" href="css/prettyphoto.css">
<script src="js/libs/jquery-1.7.2.min.js"></script>