/examples-no-jquery/slider-with-bullet-navigator.source.html

https://github.com/DIGININJADEV/jquery-slider · HTML · 99 lines · 81 code · 6 blank · 12 comment · 0 complexity · 8b4e2d9429eef9d24a815bdb2165cb14 MD5 · raw file

  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width">
  6. <title>Bullet Navigator Example - Jssor Slider, Slideshow</title>
  7. </head>
  8. <body style="font-family:Arial, Verdana;background-color:#fff;">
  9. <!-- use jssor.slider.min.js instead for release -->
  10. <!-- jssor.slider.min.js = (jssor.core.js + jssor.utils.js + jssor.slider.js) -->
  11. <script type="text/javascript" src="../js/jssor.core.js"></script>
  12. <script type="text/javascript" src="../js/jssor.utils.js"></script>
  13. <script type="text/javascript" src="../js/jssor.slider.js"></script>
  14. <script>
  15. jssor_slider1_starter = function (containerId) {
  16. var options = {
  17. $DragOrientation: 3, //[Optional] Orientation to drag slide, 0 no drag, 1 horizental, 2 vertical, 3 either, default value is 1 (Note that the $DragOrientation should be the same as $PlayOrientation when $DisplayPieces is greater than 1, or parking position is not 0)
  18. $BulletNavigatorOptions: { //[Optional] Options to specify and enable navigator or not
  19. $Class: $JssorBulletNavigator$, //[Required] Class to create navigator instance
  20. $ChanceToShow: 2, //[Required] 0 Never, 1 Mouse Over, 2 Always
  21. $ActionMode: 1, //[Optional] 0 None, 1 act by click, 2 act by mouse hover, 3 both, default value is 1
  22. $AutoCenter: 0, //[Optional] Auto center navigator in parent container, 0 None, 1 Horizontal, 2 Vertical, 3 Both, default value is 0
  23. $Steps: 1, //[Optional] Steps to go for each navigation request, default value is 1
  24. $Lanes: 1, //[Optional] Specify lanes to arrange items, default value is 1
  25. $SpacingX: 0, //[Optional] Horizontal space between each item in pixel, default value is 0
  26. $SpacingY: 0, //[Optional] Vertical space between each item in pixel, default value is 0
  27. $Orientation: 1 //[Optional] The orientation of the navigator, 1 horizontal, 2 vertical, default value is 1
  28. }
  29. };
  30. var jssor_slider1 = new $JssorSlider$(containerId, options);
  31. };
  32. </script>
  33. <!-- Jssor Slider Begin -->
  34. <!-- You can move inline styles to css file or css block. -->
  35. <div id="slider1_container" style="position: relative; top: 0px; left: 0px; width: 600px;
  36. height: 300px;">
  37. <!-- Loading Screen -->
  38. <div u="loading" style="position: absolute; top: 0px; left: 0px;">
  39. <div style="filter: alpha(opacity=70); opacity:0.7; position: absolute; display: block;
  40. background-color: #000000; top: 0px; left: 0px;width: 100%;height:100%;">
  41. </div>
  42. <div style="position: absolute; display: block; background: url(../img/loading.gif) no-repeat center center;
  43. top: 0px; left: 0px;width: 100%;height:100%;">
  44. </div>
  45. </div>
  46. <!-- Slides Container -->
  47. <div u="slides" style="cursor: move; position: absolute; left: 0px; top: 0px; width: 600px; height: 300px;
  48. overflow: hidden;">
  49. <div><img u="image" src="../img/landscape/01.jpg" /></div>
  50. <div><img u="image" src="../img/landscape/02.jpg" /></div>
  51. <div><img u="image" src="../img/landscape/03.jpg" /></div>
  52. <div><img u="image" src="../img/landscape/04.jpg" /></div>
  53. <div><img u="image" src="../img/landscape/05.jpg" /></div>
  54. <div><img u="image" src="../img/landscape/06.jpg" /></div>
  55. <div><img u="image" src="../img/landscape/07.jpg" /></div>
  56. <div><img u="image" src="../img/landscape/08.jpg" /></div>
  57. </div>
  58. <!-- Bullet Navigator Skin Begin -->
  59. <style>
  60. /* jssor slider bullet navigator skin 03 css */
  61. /*
  62. .jssorb03 div (normal)
  63. .jssorb03 div:hover (normal mouseover)
  64. .jssorb03 .av (active)
  65. .jssorb03 .av:hover (active mouseover)
  66. .jssorb03 .dn (mousedown)
  67. */
  68. .jssorb03 div, .jssorb03 div:hover, .jssorb03 .av
  69. {
  70. background: url(../img/b03.png) no-repeat;
  71. overflow:hidden;
  72. cursor: pointer;
  73. }
  74. .jssorb03 div { background-position: -5px -5px; }
  75. .jssorb03 div:hover, .jssorb03 .av:hover { background-position: -35px -5px; }
  76. .jssorb03 .av { background-position: -65px -5px; }
  77. .jssorb03 .dn, .jssorb03 .dn:hover { background-position: -95px -5px; }
  78. </style>
  79. <!-- bullet navigator container -->
  80. <div u="navigator" class="jssorb03" style="position: absolute; bottom: 4px; left: 6px;">
  81. <!-- bullet navigator item prototype -->
  82. <div u="prototype" style="position: absolute; width: 21px; height: 21px; text-align:center; line-height:21px; color:white; font-size:12px;"><NumberTemplate></NumberTemplate></div>
  83. </div>
  84. <!-- Bullet Navigator Skin End -->
  85. <a style="display: none" href="http://www.jssor.com">javascript</a>
  86. <!-- Trigger -->
  87. <script>
  88. jssor_slider1_starter('slider1_container');
  89. </script>
  90. </div>
  91. <!-- Jssor Slider End -->
  92. </body>
  93. </html>