Keeping the posts unique in every way should be the aim of every blogger. The Number list (ol) and Bullet list (ul) is an important part of a good article. To change the entire look and feel of these lists we will use simple CSS effects to bring about a change in bullets and number style on mouse hover. This tutorial consists of two very interesting parts,
- Change Bullet list (un-ordered list) style on Mouse Hover
- Change Number List (order list) style on Mouse Hover
Change Bullet list (ul) style on Mouse Hover
Before I may start lets see a Live Demo. Make sure you hit the Preview button.
To add this effect to your posts, do the following,
- Log into Blogger
- Go To Layout > Edit HTML
- Now add this piece of code just above ]]></b:skin>
.post ul {list-style-type: circle;
}.post ul li {
line-height: 1.5em;
color:#289728;
}.post ul li:hover {
color:#0080ff;
list-style-type: disc;
}
.post ul p { color:#555555;
line-height:1.4em; }
You can change the colors with any Hexa Decimal Value you like and can also change list-style-type: with many options like : circle, disc or square.
- Save Your template
Now whenever you create a bullet list in your posts make a minor change to it by adding p tag to it. How? Read below,
- Once you have created a bullet list in your post switch to the EDIT HTML Section and search for <ul> You will find a code something like below,
<ul>
<li>Your Content Here</li>
<li>Your Content Here</li>
</ul>
It doesn’t matter if the code appears horizontally. You just need to replace <li> with <li><p> and </li> with </p></li> . Replace them as many times as they appear. Now the code will look like this,
<ul>
<li><p>Your Content Here</p></li>
<li><p>Your Content Here</p></li>
</ul>
Publish your post and enjoy the new bullet style.
Change Number List (ol) style on Mouse Hover
See a Live Preview First.
To add this effect to your posts, do the following,
- Log into Blogger
- Go To Layout > Edit HTML
- Now add this piece of code just above ]]></b:skin>
.post ol {
font: italic 1em Georgia, Times, serif;
color: #999999;
}.post ol li {
line-height: 1.4em;
font: italic 1em Georgia, Times, serif;
color: #289728;
}.post ol li:hover {
font:bold italic 1em Georgia, Times, serif;
color: #0080ff;
}.post ol p {
font: normal 1em Arial, Helvetica, sans-serif;
color: #555555;
line-height:1.4em;
}
Change the colors to suit your preferences. For help use our color chart.
- Save your template
Now whenever you write a post and use a number list just make similar changes to the code in edit html section as you did for un-ordered list. But this time instead of searching for <ul> search for <ol> Make sure you change <li> with <li><p> and </li> with </p></li>
That’s it! preview you template to see the new change in number list.
Hope you loved this new way of learning and applying CSS effects to your templates :>
Update:- To learn how to add Image Bullet List with hover effect then click here
No comments:
Post a Comment