需要帮助设置一个jQuery插件“SpriteSpin”

时间:2022-02-13 02:05:02

Here is the plugin page: http://spritespin.ginie.eu/howto.html

这是插件页面:http://spritespin.ginie.eu/howto.html

Here is my site: http://chronox.netai.net/

这是我的网站:http://chronox.netai.net/

Scroll down to the very bottom to see the issue.

向下滚动到最底部以查看问题。

I want that plugin inside the last section (the slider with arrows and the '360*'.

我想在最后一节内插入该插件(带箭头的滑块和'360 *'。

I've followed the instructions. But obviously it's not showing up. Can someone take a look at the code and see if it's right?

我按照说明操作了。但显然它没有出现。有人可以看看代码,看看它是否正确?

  <script type="text/javascript">
  $(".threesixty-gold").spritespin({
  // path to the source images.
  source: [
  "assets/img/threesixty/gold/gold0000.jpg",
  "assets/img/threesixty/gold/gold0001.jpg",
  "assets/img/threesixty/gold/gold0002.jpg",
  "assets/img/threesixty/gold/gold0003.jpg",
  "assets/img/threesixty/gold/gold0004.jpg",
  "assets/img/threesixty/gold/gold0005.jpg",
  "assets/img/threesixty/gold/gold0006.jpg",
  "assets/img/threesixty/gold/gold0007.jpg",
  "assets/img/threesixty/gold/gold0008.jpg",
  "assets/img/threesixty/gold/gold0009.jpg",
  "assets/img/threesixty/gold/gold0010.jpg",
  "assets/img/threesixty/gold/gold0011.jpg",
  "assets/img/threesixty/gold/gold0012.jpg",
  "assets/img/threesixty/gold/gold0012.jpg",
  "assets/img/threesixty/gold/gold0013.jpg",
  "assets/img/threesixty/gold/gold0014.jpg",
  "assets/img/threesixty/gold/gold0015.jpg",
  "assets/img/threesixty/gold/gold0016.jpg",
  "assets/img/threesixty/gold/gold0017.jpg",
  "assets/img/threesixty/gold/gold0018.jpg",
  "assets/img/threesixty/gold/gold0019.jpg",
  "assets/img/threesixty/gold/gold0020.jpg",



  ],
  width   : 1900,  // width in pixels of the window/frame
  height  : 930,  // height in pixels of the window/frame
});

</script>

2 个解决方案

#1


2  

you need to put your code in $( document ).ready(function() {});
updated
you are missing spritespin.js reference.
<script src='spritespin.js' type='text/javascrip' />

你需要把你的代码放在$(document).ready(function(){});更新了你缺少spritespin.js参考。

#2


0  

You need to include sprite js in your html. You may insert it right after jquery.

你需要在你的HTML中包含sprite js。你可以在jquery之后插入它。

<script src='jquery-1.4.2.js' type='text/javascript' />
<script src='spritespin.js' type='text/javascrip' />

#1


2  

you need to put your code in $( document ).ready(function() {});
updated
you are missing spritespin.js reference.
<script src='spritespin.js' type='text/javascrip' />

你需要把你的代码放在$(document).ready(function(){});更新了你缺少spritespin.js参考。

#2


0  

You need to include sprite js in your html. You may insert it right after jquery.

你需要在你的HTML中包含sprite js。你可以在jquery之后插入它。

<script src='jquery-1.4.2.js' type='text/javascript' />
<script src='spritespin.js' type='text/javascrip' />