Membuat Sebuah Simple Featured Content SlideShow Menggunakan JQuery

menu slider simple menggunakan JQuery untuk template blogger
View Demo

InsyaAllah postingan kali ini, kembali saya ingin mengetengahkan tutorial penerapan JQuery pada template blogger. Berbeda dari tutorial-tutorial sebelumnya dimana source saya peroleh dari web-web designer luar, maka tutorial kali ini lahir dari hasil pengamatan pada sebuah free blogger template yang dikenal dengan Elegant Dashboard, tidak jauh berbeda dengan lahirnya tutorial terdahulu dengan judul menu slider versi 2 yang juga saya pelajari dari free blogger template Zinmag Primus. Bagi yang belum pernah mencoba membuat menu slider versi 2 seperti screenshot berikut, silahkan klik disini, atau silahkan lihat dulu demo featured content slider post using JQuery/ menu slider versi 2 menggunakan JQuery disini
menu slider simple menggunakan JQuery untuk template blogger
Nah sekarang langsung pada tutorial, cara membuat simple content slideshow menggunakan JQuery
1. Setelah sig in pada account blogger sobat>>> pada dasbor>>> Klik Tata Letak>>> Edit HTML
2. Tambahkan Script JQuery berikut sebelum tag </head>
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js' type='text/javascript'/> catatan: bagi sobat yang sudah pernah menambahkan atau pada templatenya sudah terdapat script JQuery maka langkah kedua abaikan saja.
3. Tambahkan juga script berikut setelah script JQuery tadi

<script type='text/javascript'>
//<![CDATA[
$(document).ready(function(){var currentPosition=0;var slideWidth=845;var slides=$('.slide');var numberOfSlides=slides.length;$('#slidesContainer').css('overflow','hidden');slides.wrapAll('<div id="slideInner"></div>').css({'float':'left','width':slideWidth});$('#slideInner').css('width',slideWidth*numberOfSlides);$('#slideshow').prepend('<span class="control" id="leftControl">Clicking moves left</span>').append('<span class="control" id="rightControl">Clicking moves right</span>');manageControls(currentPosition);$('.control').bind('click',function(){currentPosition=($(this).attr('id')=='rightControl')?currentPosition+1:currentPosition-1;manageControls(currentPosition);$('#slideInner').animate({'marginLeft':slideWidth*(-currentPosition)})});function manageControls(position){if(position==0){$('#leftControl').hide()}else{$('#leftControl').show()}if(position==numberOfSlides-1){$('#rightControl').hide()}else{$('#rightControl').show()}}
});
//]]>
</script>

4. Selanjutnya tambahkan kode CSS berikut diatas tag  ]]></b:skin>
#contentSlide {
background : #ddd;
height : 228px;
padding : 10px 0;
}
#slideshow {
margin : 0 auto;
width : 945px;
height : 230px;
background : #eeeeee none repeat scroll 0 0;
position : relative;
}
#slideshow #slidesContainer {
margin : 0 auto;
width : 845px;
height : 228px;
overflow : auto;
position : relative;
}
#slideshow #slidesContainer .slide {
margin : 0 auto;
width : 845px;
height : 228px;
}
.control {
display : block;
width : 39px;
height : 228px;
text-indent : -10000px;
position : absolute;
cursor : pointer;
}
#leftControl {
top : 0;
left : 0;
width : 55px;
background : transparent url(http://lh6.ggpht.com/_9b1traaMESE/Sms_Pg_IsqI/AAAAAAAAAXU/tTxdiIsFY4g/previous%20gray.jpg)no-repeat scroll 0 0;
}
#rightControl {
top : 0;
right : 0;
background : transparent url(http://lh6.ggpht.com/_9b1traaMESE/Sms-s5qb9iI/AAAAAAAAAXQ/edpXAZIaxCI/next%20gray.jpg) no-repeat scroll 0 0;
width : 55px;
}
.slide h2, .slide p {
margin : 15px;
}
.slide h2 {
font : italic 24px Georgia, "Times New Roman", Times, serif;
color : #212421;
letter-spacing : -1px;
}
.slide img {
float : right;
margin : 0 15px;
padding : 1px; 
}
Catatan: masih memungkinkan bagi sobat untuk mengedit CSS diatas, seperti mengganti labar dan tinggi dari content, fariasi border, atau merubah warna background dan image. Untuk kode warna silahkan lihat disini.
5. Terakhir tambahkan kode HTML berikut diatas <div id='content-wrapper'>
<!-- Slideshow HTML -->
<div id='contentSlide'><div id='slideshow'>
<div id='slidesContainer'>
<div class='slide'>
<h2>Featured Content Slider Using JQuery!</h2>
<p><a href='http://amatullah83.blogspot.com/2010/02/featured-content-slider-using-jquery.html'><img alt='External links - Jquery' height='115' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjxGi97GJllIwc5ad50fdxLzf1A_c-B-vK2L7C2y-MozgWTX_723w0nyQTqETiI1Lx0cto-fZXzPL4X1dH0ftcGleIweDYDrpW0puukj1BfBwxzD-mZCH41KYOhXTKM4A0w1OvK4Rb4-QGO/?imgmax=800' width='215'/></a> Featured Content Slider Using JQuery. Both of these examples use the featured Slider pretty much &#8220;out of the box&#8221;. Sure the design was heavily altered to fit the job, but the actual functionality wasn&#8217;t altered in any way. I recently had the calling to build a &#8220;featured content area&#8221;.</p>
<p>All you need to try it here you wont be sorry ! go try it GUMGUM :) <a href='http://amatullah83.blogspot.com/2010/02/featured-content-slider-using-jquery.html' target='_blank'>visit my another explained post</a> about this tutorial</p>
</div>
<div class='slide'>
<h2>Thumbnail With Caption Using Simple JQuery</h2>
<p><a href='http://amatullah83.blogspot.com/2010/02/membuat-sebuah-thumbnail-dengan-caption.html'><img alt='External links - Jquery' height='115' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjfeXB3l5TTl3dRFgOy1S_0zjpbx_NR05zzTJXUqDNYEnIEUVZetJygCUQABlIzJ3yufm0cS86so_3J6x3hh3wAidGBfeB6xYdKalHSWWp9blkzG4o5nYSHOLWAsPcf7wDKEA0COIvDGLM/?imgmax=800' width='215'/></a> This tutorial will show how to add heading and caption to your thumbnail and display it with jQuery cool transition effect. It&#39;s an elegant way to put content in your website, and only display it when users want to see it. It keeps your website clean!..</p>
<h3>How to Create a Thumbnail With Caption Using Simple JQuery? <a href='http://amatullah83.blogspot.com/2010/02/membuat-sebuah-thumbnail-dengan-caption.html' target='_blank'>GO HERE AND READ HOW</a> :)</h3>
</div>
<div class='slide'>
<h2>Multi Level Drop-Down Menu Dengan CSS dan JQuery!</h2>
<p><a href='http://amatullah83.blogspot.com/2010/02/multi-level-drop-down-menu-dengan-css.html'><img alt='External links - Jquery' height='115' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvBrhEfOfn8zttD0nACtlde1ppDAqxbeNuUyC6yGtor7tf-89aEda0lqAB_Hy6lqJOz0UAI7l-SvPu4ArpPnqwS-H3qvziXRGFaoAaZdn5xFdudEzAQNRSnWlS358rBM4mcPrGKh_UPKg/?imgmax=800' width='215'/></a> This is a multi-level horizontal CSS menu created using a regular nested HTML list, then turned into a fully functional drop down menu using CSS and a touch of jQuery. The sub menus slide in and out into view, which also automatically reposition themselves horizontally if too close to the window&#39;s right edge. If you want to create it in your blogger blog, here&#39;s what you should do ! (these instructions refer to the &quot;new&quot; Blogger layouts templates) <a href='http://amatullah83.blogspot.com/2010/02/multi-level-drop-down-menu-dengan-css.html' target='_blank'>GO GET IT GUMGUM:)</a></p>
</div>
<div class='slide'>
<h2>Super Sexy Bookmarks Widget for Blogger !</h2>
<p><a href='http://amatullah83.blogspot.com/2010/02/cara-memasang-widget-sexy-sosial.html'><img alt='Thumbnail image that says sleek button using photoshop that links to a Photoshop tutoril.' height='115' src='https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjMEqsPQLbaS9dnnZVdso80e2eYiUWTOR4dLdBYLXO-_jKvXxzJJq_AOJoRynXaV61LS8evZN0BtSt9JdryWh0VX57TfEuG11ofQ3dkJAOJLLI8tET5HwLjxu8Z2tjmb6mF9ovi2zw2Ps4/?imgmax=800' width='215'/></a> Looking for professional Social Bookmark Buttons for your blog ! me too :) however, while i was searching the net too, I came across a post by Naeemnur, that had instructions for Blogger (BlogSpot.com) based blogs which was really good.If you have a blog on blogger you can definitely give this a try. </p>
<p>Its very attractive social bookmarking widget ! it can help you to let your visitors bookmark your page effectively .</p>
<p>for instructions about the use of this SEXY Social bookmarking widget ! <a href='http://amatullah83.blogspot.com/2010/02/cara-memasang-widget-sexy-sosial.html' target='_blank'>you can go here and get it GUMGUM:)</a></p>
</div>
</div>
</div></div>
<!-- Slideshow HTML -->
<div class='clear'/>
Catatan: Silahkan sobat edit Judul dari content, deskripsi dan link content.
>6. Simpan dan simpan lagi. Silahkan lihat hasilnya diblog sobat.
Selamat mencoba, semoga berhasil, semoga bermanfaat.
Salam.
0 Komentar untuk "Membuat Sebuah Simple Featured Content SlideShow Menggunakan JQuery"