s4f11sn

Create a CSS Image Slider with Thumbnails for Blogger

Feb 4th, 2014
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.46 KB | None | 0 0
  1. Create a CSS Image Slider with Thumbnails for Blogger
  2.  
  3.  
  4. paste kode berikut di atas kode </head>
  5. pilih stile;//
  6.  
  7.  
  8. <style type='text/css'>
  9. .image-container {
  10. position: relative;
  11. width: 640px;
  12. height: 530px;
  13. margin: 0 auto;
  14. text-align:center;
  15. overflow: hidden;
  16. }
  17. .image-container a {
  18. display: inline;
  19. text-decoration: none;
  20. }
  21.  
  22. /* Mini-thumbnails style */
  23. .mini-thumbnail {
  24. width: 18%; /* mini-thumbnails width */
  25. margin:1px;
  26. opacity: 1;
  27. -webkit-box-shadow: 0px 0px 3px rgba(0,0,0,0.5);
  28. -moz-box-shadow: 0px 0px 3px rgba(0,0,0,0.5);
  29. box-shadow: 0px 0px 3px rgba(0,0,0,0.5);
  30. }
  31.  
  32. /* Style for the main thumbnail */
  33. .large-thumbnail {
  34. position: absolute;
  35. width: 100%;
  36. top: 800px;
  37. margin:0 auto;
  38. text-align: center;
  39. display: block;
  40. -webkit-transition: top 1s ease;
  41. -moz-transition: top 1s ease;
  42. -o-transition: top 1s ease;
  43. -ms-transition: top 1s ease;
  44. transition: top 1s ease;
  45. }
  46. .feature {
  47. top: 110px;
  48. width: 100%;
  49. opacity: .3;
  50. }
  51.  
  52. /* style for the selected mini-thumbnail */
  53. a:hover .mini-thumbnail {
  54. opacity: .5;
  55. -webkit-box-shadow: 0px 0px 10px rgba(0,0,0,0.5);
  56. -moz-box-shadow: 0px 0px 10px rgba(0,0,0,0.5);
  57. box-shadow: 0px 0px 10px rgba(0,0,0,0.5);
  58. }
  59.  
  60. /* transition effects for the selected image */
  61. a:hover .large-thumbnail {
  62. top: 110px;
  63. width: 100%;
  64. z-index:3;
  65. opacity: 1;
  66. -webkit-transition: top 1s ease;
  67. -moz-transition: top 1s ease;
  68. -o-transition: top 1s ease;
  69. -ms-transition: top 1s ease;
  70. transition: top 1s ease;
  71. }
  72. </style>
  73.  
  74. save template
  75.  
  76. go to html:
  77.  
  78. paste kode
  79.  
  80. <div class="image-container">
  81. <a href="javascript:void(0);">
  82. <img class="mini-thumbnail" src="MINI-THUMB-URL1" />
  83. <img class="large-thumbnail" src="LARGE-THUMB-URL1" />
  84. </a>
  85. <a href="javascript:void(0);">
  86. <img class="mini-thumbnail" src="MINI-THUMB-URL2" />
  87. <img class="large-thumbnail" src="LARGE-THUMB-URL2" />
  88. </a>
  89. <a href="javascript:void(0);">
  90. <img class="mini-thumbnail" src="MINI-THUMB-URL3" />
  91. <img class="large-thumbnail" src="LARGE-THUMB-URL3" />
  92. </a>
  93. <a href="javascript:void(0);">
  94. <img class="mini-thumbnail" src="MINI-THUMB-URL4" />
  95. <img class="large-thumbnail" src="LARGE-THUMB-URL4" />
  96. </a>
  97. <a href="javascript:void(0);">
  98. <img class="mini-thumbnail" src="MINI-THUMB-URL5" />
  99. <img class="large-thumbnail" src="LARGE-THUMB-URL5" />
  100. </a>
  101. <a href="javascript:void(0);">
  102. <img class="large-thumbnail feature" src="LARGE-THUMB-URL1" />
  103. </a>
  104. </div>
  105.  
  106.  
  107. from: http://helplogger.blogspot.com/2014/01/create-css-image-slider-with-thumbnails.html
Advertisement
Add Comment
Please, Sign In to add comment