|
|
I've got another interesting tutorial using jQuery - four in a row. However, it's very important to note that all these effects are possible with the inclusion of one single jQuery file on your template which means no additional time to load your site. In this article, I'll teach you another simple slide effect or in other words, an up/down slide panel effect using jQuery. Take a look at the demo below...
Interesting? Well, I have implemented the hack within the article on the demo blog whereas you can implement the same anywhere on your blogger template. Few examples include adding it to the sidebar with facebook like box, adding the hack to wrap the featured section, add the effect below your articles to show the share icons/author info widget, etc... So, let's get started.
1. Navigate to "Design>>Edit HTML" and make a backup of your template by clicking on the "Download full template" link at the top of the page. Once the back up is over, search for the following piece of code.
3. Next, search for the following piece of code.
Note: You need not paste the first line (highlighted in orange) in the above coding if you already have the jquery file running on your blog.
5. Now, insert the following tags anywhere in your template - may be within the post editor (or) on your template. Replace YOUR CONTENT HERE with any content you want - it can be a script or an image or a link, anything under the earth... lol....
The above slide panel effect was tested to work on all major browsers - IE, Firefox, Chrome, Opera. We are happy to inform our readers that some of my design articles have started to appear on the famous design site - Design News. I hope we'll be able to provide such quality articles in the future as well! Share your opinions via comments!
SLIDE PANEL EFFECT ON BLOGGER USING JQUERY - LIVE DEMO
Interesting? Well, I have implemented the hack within the article on the demo blog whereas you can implement the same anywhere on your blogger template. Few examples include adding it to the sidebar with facebook like box, adding the hack to wrap the featured section, add the effect below your articles to show the share icons/author info widget, etc... So, let's get started.
1. Navigate to "Design>>Edit HTML" and make a backup of your template by clicking on the "Download full template" link at the top of the page. Once the back up is over, search for the following piece of code.
]]></b:skin>
2. Paste the following piece of code just above the line mentioned step 1.#panel {
background: #D3D3D3;
height: 190px;
color:#000;
display: none;
margin-top:15px;
}
.slide-panel {
margin: 0;
padding: 0;
border-top: solid 0px #422410;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiXnssFHhP35djP8H7JjqKbErsHRlRcXvNcjEffuGuu2_aGHtTo3g-tE5E183KoBt2yqApvW9eMMLFXNLyiYzPJ0GNd_z7M6c5LaK_sMmB3sz3WbO4R4hSW2Uc97IJkU8R_0x7HZfAtTQDe/s144/orange-slide.png) no-repeat center top;
}
.btn-slide {
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjEB98jgC_T-9fK9P6SHJkkbJSPcTFFwLjEtIG5Lm4UM0WI-vNtNCjMphXPAcB6FHbUQq2H82Nd8f8tpqfo7oI8Q29hbvznV-8ubQSAX1rG3FmCyxV3iDfusS7myvDARhm-0-94KUGvf2Pk/s800/white-arrow.gif) no-repeat right -50px;
text-align: center;
width: 144px;
height: 31px;
padding: 8px 10px 0 0;
margin: 0 auto;
display: block;
font: bold 120%/100% Arial, Helvetica, sans-serif;
color: #fff;
text-decoration: none;
}
.active {
background-position: right 12px;
}
background: #D3D3D3;
height: 190px;
color:#000;
display: none;
margin-top:15px;
}
.slide-panel {
margin: 0;
padding: 0;
border-top: solid 0px #422410;
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiXnssFHhP35djP8H7JjqKbErsHRlRcXvNcjEffuGuu2_aGHtTo3g-tE5E183KoBt2yqApvW9eMMLFXNLyiYzPJ0GNd_z7M6c5LaK_sMmB3sz3WbO4R4hSW2Uc97IJkU8R_0x7HZfAtTQDe/s144/orange-slide.png) no-repeat center top;
}
.btn-slide {
background: url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjEB98jgC_T-9fK9P6SHJkkbJSPcTFFwLjEtIG5Lm4UM0WI-vNtNCjMphXPAcB6FHbUQq2H82Nd8f8tpqfo7oI8Q29hbvznV-8ubQSAX1rG3FmCyxV3iDfusS7myvDARhm-0-94KUGvf2Pk/s800/white-arrow.gif) no-repeat right -50px;
text-align: center;
width: 144px;
height: 31px;
padding: 8px 10px 0 0;
margin: 0 auto;
display: block;
font: bold 120%/100% Arial, Helvetica, sans-serif;
color: #fff;
text-decoration: none;
}
.active {
background-position: right 12px;
}
Note: You may replace the color code highlighted in blue to change the background of the panel. Similarly, the text color by varying the code highlighted in green. To change the height of the panel, vary the code highlighted in orange. You can also change the color of the slide button by varying the URL highlighted in pink. We have provided six different buttons below. Pick one from the slot that interests you!
</head>
4. Paste the following piece of code just above the line mentioned in step 3. Save your template.<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js' type='text/javascript'/>
<script type='text/javascript'>
$(document).ready(function(){
$(".btn-slide").click(function(){
$("#panel").slideToggle("slow");
$(this).toggleClass("active"); return false;
});
});
</script>
5. Now, insert the following tags anywhere in your template - may be within the post editor (or) on your template. Replace YOUR CONTENT HERE with any content you want - it can be a script or an image or a link, anything under the earth... lol....
<div id="panel">
YOUR CONTENT HERE
</div>
<div class="slide-panel">
<a href="#" class="btn-slide">Slide Panel</a>
</div>
6. That's it! Save your template just in case you made use of the code on your template else, publish the post with codes mentioned in step 5 and you're done!YOUR CONTENT HERE
</div>
<div class="slide-panel">
<a href="#" class="btn-slide">Slide Panel</a>
</div>
The above slide panel effect was tested to work on all major browsers - IE, Firefox, Chrome, Opera. We are happy to inform our readers that some of my design articles have started to appear on the famous design site - Design News. I hope we'll be able to provide such quality articles in the future as well! Share your opinions via comments!
Click here to subscribe to FREE email updates from "Everything About Blogging", so that you do not miss out anything that can be valuable to you and your blog!
Dear,
REPLYOn Demo page,there's impressive hover image effect, Please share tip on how to apply it
Thanks a lot.
@Born to Trade: Well, I guess you are asking about the pop out details effect on image hover. Right? I'll soon publish an article about the same on my blog! So, stay tuned:)
REPLYThanks, have you posted about lightbox or prettyphoto image slide effect ?
REPLY@Born to Trade: Well, I have few articles coming up about light-box effects on my blog! You need to wait a little bit! Anyway, thanks for the comment buddy!
REPLYcan this be applied to wordpress blog?And all your tutorials are they for wordpress blogs or bloggers blog or both..very nice tutorial
REPLY@Jaypei: Well, I post article specifically for blogs on blogspot/blogger. However, the same can be applied to WordPress blogs provided you know a little bit of php to modify the same code and get it work on WP. Thanks for the comment buddy!
REPLYHey Mukund,
REPLYThanks for this! Implemented it on my blog, but I have a problem, You may want to check it out at http://likelitelife.blogspot.com/p/about-us.html. I cannot tell you what the problem is, so it's better if you take a look!
Aditya Samitinjay
@Aditya Samitinjay: Well, the problem is pretty simple! Login to your dashboard and edit the post where the slider is installed. Now, look for the href tag for the slide icon. You'll notice some stuff like "blogger.com?post...."! Just remove that stuff and add a '#' tag as the value to the attribute href! That's it! Your problem solved!
REPLYi modified the image to have round corners with transparent effect and replaced the original image....its extension wz changed frm .gif to .png.......but when i am clicking on the sidebar button which is visible before clicking; after clicking it it doesn't show...please help!!!!
REPLY@SakeT KumaR: Sure! Just ping me on gtalk or email me stating what your problem is - probably with a screen shot and I'll help you out:)
REPLYThis is an impressive tip! Thanks for your share.
REPLY@Lee Peace: Yup! Thanks for the comment! I hope you enjoy the other tutorials on my blog as well!
REPLY@Mukund Can I set height for each post? For example, in post 1, I want to set height: 450px, in post 2, I want to set height: 550px?
REPLY@Lee Peace: Yes! You can do that! You need to repeat the CSS with different id so that each has a different height. A little modification in the coding will do good:)
REPLY@Mukund Thanks for your reply! I love your tips so much.
REPLY@Mukund Can you give me an example? Although I use different ID, it doesn't work.
REPLY@Lee Peace: I guess I can explain stuffs better via email or chat! I would be happy if you can contact me via email stating your problem! I ll try to provide a solution after testing it on my demo blog:)
REPLYhow can I put the button on top of the page?
REPLY@manu: Place the codes just at the opening of body tag so that it appears on top! Need further help? Then, hit me via gmail!
REPLYThis lesson does not work in my template?
REPLYUse the tab below to comment. No spam please!!!
POST YOUR COMMENT