Auto Move Image Slider i.e carousel For Blogger



I had provided you earlier with an image slider with two left and right panels which on click take you to other images.But some of my readers at that time wanted it to have auto moves of images in slider.So in this post i will tell you how to auto move the images in slider.If you you don't know what exactly image slider is, then don't worry, just i would like you first to read my previous post on image slider for it and if you like it just follow that tutorial to have it in your blog.

Some other widgets you would like to implement for sure like peel add for blogger for attracting your visitors to subscribe your blog or show of your advertiser or show of some other important stuff.Some hacks like these i previously wrote were image hover effect,images reflection in blogger posts and zoom your images in blogger posts,which might also help you a lot.

Now lets carry on with an important tutorial of how to add the auto move image slider to your blog.



Just see it at top below the blog header.

Download this Zip file and get two javascript files from it for backup.


Now after getting these two scripts you can upload them to your own server,if you want else dont know where to upload check my this post on where to upload .js files.

Now Just login to your blogger account Then Go To > Layout > Edit/Html > Press Ctrl+ F

Now search for </head> and place the below javascript codes before this tag.

<script src='http://btemplatescripts.googlecode.com/files/auto-slider.js' type='text/javascript'/>
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.min.js' type='text/javascript'/>

In the above codes you will see red coloured lines just replace them with the link of your file which you downloaded and uploaded to your server, if dont want then also you can use my above links.

Now Search for this code ]]></b:skin> and add the below css above it.

#myslides{
background:#000 url(http://1.bp.blogspot.com/_xfdD6S9fOk4/Sd1SjSaUrXI/AAAAAAAAA20/ndvDf0nTslY/s1600/mslid.jpg) repeat-x;
width: 650px;
height:165px;
margin-bottom:5px;
}

.stepcarousel{
position: relative; /*leave this value alone*/
overflow: scroll; /*leave this value alone*/
width: 554px; /*Width of Carousel Viewer itself*/
height: 160px; /*Height should enough to fit largest content's height*/
margin: 0px 48px 5px 48px;

}

.stepcarousel .belt{
position: absolute; /*leave this value alone*/
left: 0;
top: 0;
}

.stepcarousel .panel{
float: left; /*leave this value alone*/
overflow: hidden; /*clip content that go outside dimensions of holding panel DIV*/
margin: 20px 10px ; /*margin around each panel*/
width:170px; /*Width of each panel holding each content. If removed, widths should be individually defined on each content DIV then. */
background:#0e1829;
height:120px;
border:1px solid #1d2c44;

}
.stepcarousel .panel p{
text-align: left; /*leave this value alone*/
overflow: hidden; /*clip content that go outside dimensions of holding panel DIV*/
margin: 5px 5px ; /*margin around each panel*/

}

.stepcarousel .panel h2{
text-align: left; /*leave this value alone*/
height:20px;
overflow: hidden; /*clip content that go outside dimensions of holding panel DIV*/
margin: 2px 5px ; /*margin around each panel*/
font-size:16px;
font-weight:bold;
text-align:center;
font-family:Georgia,century gothic,Arial,verdana, sans-serif;
}

.stepcarousel .panel img{
float: left; /*leave this value alone*/
background:#0E1829; /*clip content that go outside dimensions of holding panel DIV*/
margin: 5px 5px 5px 5px; /*margin around each panel*/
padding:0px 0px;
}

Above in code is red line with url of background image of slider,you can also change it to adjust your blog.

Special Step


Just Find for /head tag and place the below script above it.

<script type='text/javascript'>
stepcarousel.setup({
galleryid: &#39;mygallery&#39;, //id of carousel DIV
beltclass: &#39;belt&#39;, //class of inner &quot;belt&quot; DIV containing all the panel DIVs
panelclass: &#39;panel&#39;, //class of panel DIVs each holding content
autostep: {enable:true, moveby:1, pause:6000},
panelbehavior: {speed:500, wraparound:true, persist:true},
defaultbuttons: {enable: true, moveby: 3, leftnav: [&#39;http://1.bp.blogspot.com/_v5IxGTiMTD8/SxOlAIA_ZZI/AAAAAAAAAfg/ELVwF1qY8M8/s400/left.jpg&#39;, -48, 0], rightnav: [&#39;http://1.bp.blogspot.com/_v5IxGTiMTD8/SxOlAVn-OvI/AAAAAAAAAfo/kMJcmlXZKCs/s400/right.jpg&#39;, 0, 0]},
statusvars: [&#39;statusA&#39;, &#39;statusB&#39;, &#39;statusC&#39;], //register 3 variables that contain current panel (start), current panel (last), and total panels
contenttype: [&#39;external&#39;] //content setting [&#39;inline&#39;] or [&#39;external&#39;, &#39;path_to_external_file&#39;]
})
</script>

The green lines are the images of side arrows to make it scroll left and right you can make and add your also to make it look different.And in pink are number to control speed of slider.

Now Save Your Template.All the coding part is finished,now just how to add images to slider.

Just go to Layout > Page Elements > Add A Gadget > Html/Javascript

And add the below links of images and posts in it,in the format i am writing below.

<div id="myslides">
<div id="mygallery" class="stepcarousel">
<div class="belt">

<!-- 1st Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2008/10/new-two-column-denim-template.html" target="blank" title="Two Column Denim Template"> <img width="160" alt="Two Column Denim Template" src="http://4.bp.blogspot.com/_v5IxGTiMTD8/SQTQLthrdvI/AAAAAAAAAHk/JY-ySDnZ8Xw/s400/newtwocolumndenimtemplate.jpg" height="110"/> </a>
</div>
<!-- end code of 1st -->

<!-- 2nd Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2009/02/simple-blog-writing-template.html" target="blank" title="Simple Blog Writing Template"> <img width="160" alt="Simple Blog Writing Template" src="http://4.bp.blogspot.com/_v5IxGTiMTD8/SZpu68uI7xI/AAAAAAAAAM8/4qHvgwss23o/s400/simple+Blog+Template.png" height="110"/> </a>
</div>
<!-- end code of 2nd -->

<!-- 3rd Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2009/05/woork-style-blogger-template-design.html" target="blank" title="Woork Style Blogger Template"> <img width="160" alt="Woork Style Blogger Template" src="http://img2.pict.com/91/27/d5/ad3dbaa7835b554ec0d06a4e0c/XG7ZL/800/woork2520257c2520web2520design25.png" height="110"/> </a>
</div>
<!-- end code of 3rd -->

<!-- 4th Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2009/05/blogger-buster-style-blogger-template.html" target="blank" title="Blogger Buster Style"> <img src="http://img23.imageshack.us/img23/8537/bloggertemplate.jpg"/> </a>
</div>
<!-- end code of 4th -->

<!-- 5th Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2009/05/free-lenomag-blogger-template.html" target="blank" title="Lenomag Blogger Template"> <img width="160" alt="Lenomag Blogger Template" src="http://2.bp.blogspot.com/_nX0wvumD9VU/ShkEH2GD1nI/AAAAAAAAAOY/xeVepHCMH2M/s400/Preview.jpg" height="110"/> </a>
</div>
<!-- end code of 5th -->

<!-- 6th Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2009/06/money-blogger-blogger-template.html" target="blank" title="Money Blogger Template"> <img width="160" alt="Money Blogger Template" src="http://1.bp.blogspot.com/_nX0wvumD9VU/SiuAxR7uKDI/AAAAAAAAAPE/BYtw4ToMfr4/s320/money2520blogger.png" height="110"/> </a>
</div>
<!-- end code of 6th -->

<!-- 7th Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2009/06/digital-statement-blogger-template.html" target="blank" title="Digital Statement Blogger Template"> <img width="160" alt="Digital Statement Blogger Template" src="http://img2.pict.com/fd/ad/16/9de4e09426b4090113f40930f2/bnaeY/800/digital2520statement.png" height="110"/> </a>
</div>
<!-- end code of 7th -->

<!-- 8th Template -->
<div class="panel">
<a href="http://www.anshuldudeja.com/2009/06/orkut-theme-blogger-template.html" target="blank" title="Orkut Theme Blogger Template"> <img width="160" alt="Orkut Theme Blogger Template" src="http://img2.pict.com/f3/ec/dd/06efff55a05477591153094b2f/rDVvV/800/orkut2520theme2520blogger2520tem.png" height="110"/> </a>
</div>
<!-- end code of 8th -->

</div></div></div>

Just change the links and images url with yours and also there titles.Just keep on adding links to in this format to any number you want as you can add hundreds of images and posts in this format no limit to it.Java web hosting is also rising in popularity now, so better try searching one that suits your needs now.

23 comments:

ADMIN 4ALL said...

Hi ,anshuldudeja

I try follow your step but i have some problem

can you help me

http://hackublog.blogspot.com/

Anshul said...

What help you need let me know !

Googy said...

Hi Anshul...congrats on 6 figure count!

Lively.Pk said...

hay sir,
sir jab main apna blog Internet Explorer 6, ya Internet Explorer 8 main open karta hon,

http://livelypk.blogspot.com/
to is ke left corner main error show hotay hain jis ki waja se page sahi open nahin hota, plz sir tell me, ke main ye error kis tarhan se remove kiye ja sakte hain,

im waiting for ur reply
plz reply soon
byee

Anshul said...

@lively to me seems no error in both browser.

arwin kim said...

Salam Anshul :)

I want to ask. How to use this script to run photo from Flickr?? Thanks. Namaste.

Asep Canda Blog said...

if ya do not mind a visit to my blog
thank you nice blog

Esydownloads said...

Hello Anshul
I m R.Yadav
this slider is inbuilt in my templete.and in my templete i used .js file for slider which i host a javascript hosting site but my slider is not workin i Mozilla Fire Fox but it is working in Google Crome & Opera Browser, only sliding buttons are Disappear
this all happened becaz of web2feel.com remove all the image and javascript from there site
So any Solution to repaire the slider for Mozilla Firefox
if any then Reply me I m waiting 4 ur Reply

See my blog here in Different Browser Mozilla & Crome or opera then u will understand my Problem

http://esydownloads.blogspot.com

i think ur slider is also not Working in Mozzila

Esydownloads said...

if any solution then i want to use this code
"Auto Move Image Slider i.e carousel For Blogger"
Pls help me i commented many time to "Chayabiru"
but he is not reply for this matter

Anshul said...

@esy i will see auto slider when get time as its not workin have to chack all codes again.
And hosting scripts as i know web2feel removed all scripts al you would see my slider also in problems t works but after some time there is problem again.For hosting script only the best solution is expand script and host in blogger codes only if you don't get any good server to host script.You can learn from here how to do it.http://www.anshuldudeja.com/2009/09/how-to-host-javascript-or-js-files-on.html

esydownloads said...

Slider is working in Google Crome ,Internet Explorer & Opera only button images r not appear BUT it is not working Mozilla FireFox

esydownloads said...

hey anshule i repaire my slider navigation button
pls tell me how to make "AUTO SLIDING" becoz the above code is not working pls repaire it
THX

ken said...

my blog has the problem http://filmsdb.blogspot.com/ please reply me

Anshul said...

@esydownloads i will try to fix this only if succesful will update post else i would say for auto move find any other slider codes.Or as i get time i will post other codes here.Just show me any slider you like for automove in any wordpresss blog and mail me to anshulaffprg[at]gmail.com I will instantly mail u all codes of it to have it in your blog.

@ken where is your slider.

ken said...

i think ur code mix with other js first time i had same problem
http://filmsdb.blogspot.com/

They r not scrolling automatically what i hav to do..

ken said...

I think U will get Help From here
http://www.dynamicdrive.com/dynamicindex4/stepcarousel.htm

Anshul said...

@ken i know it has problem i need to fix it or chnage all i will do when get time.and the link you showed is not auto.

Esydownloads said...

hello Anshule

see this site has a Auto Moving Slider

http://movieloo.info

Anshul said...

ok i will see them.

ken said...

I had the same problem as u first time when i added toolbar,may be that javascript file interleaves with slider scripts.then i changed it in that site wibiya. u can troubleshoot for that script in that site.Then try slider i think it will work out

Anshul said...

@all readers the slider is updated and working fine now....Thanx for your patience.

WuanLink said...

Thanks for sharing !
it's really userful widget

Rhaye said...

thx again anshul.. guys you can check mine too with a high width also.. check here http://yonipzone.com thx again anshul

Post a Comment