CSS Library: Horizontal CSS Menus: Here
Shade Image Tabs Menu
Author: Dynamic Drive
This is an attractive "blue shading" image tab menu. The shade effect is created using two gradient background images, one for the overall tabs, and the other, for the currently "active" tab. Based partially on the Basic Tabs menu, Shade Image Tabs Menu supports three commonly requested features:
- Ability to align the menu tabs "left", "center", or "right" on the page
- Highlight a particular tab so it appears selected/ active,
- Change the width of the tab menu (so the underline beneath it spans a length other than the entire width of the page.
Demo:
The two images (resized for easier download):
![]()
The CSS:
Got a question or need help customizing this CSS code? Post it in the CSS Forums. If you have a comment or suggestion instead, post it in the comments section below.
Comment Pages 3 of 7 pages « First < 1 2 3 4 5 > Last »
I tried but different tabs are not highlighted when clicked, only the default one is highlighted. Can you help? Thanks.
oh, i forgot. I changed the selector to "tabs" instead of "shadetabs".
*html .tabs li.selected
so rename .tabs to .shadetabs and it'll work ;)
*html .tabs li.selected
so rename .tabs to .shadetabs and it'll work ;)
Where you see this:
If you take out the top: 1px, then that should get rid of the problem of the 1 pixel poking through... However I am not sure if this works on IE6, as I am using IE7 && Firefox.
Other than that, this is a very good tutorial, and I will be using the code. Much thanks :)
- Jordan
.shadetabs li.selected{
position: relative;
top: 1px;
}
If you take out the top: 1px, then that should get rid of the problem of the 1 pixel poking through... However I am not sure if this works on IE6, as I am using IE7 && Firefox.
Other than that, this is a very good tutorial, and I will be using the code. Much thanks :)
- Jordan
I LOVE IT! I am planning on using your tabbed interface...but need to figure out how to have it auto-rotate through the elements unless someone clicks on a tab....or pauses as they move their mouse over the content. Please let me know if that is in the works...or already available and I just didn't see it.
Thanks!
Thanks!
Is it possible to align the menu verically on the left side of the page instead of on top?
Anyway to make the selected tab's text has a different color in IE6?
I added the color to the li.selected a, but it works in FF not in IE5
.shadetabs li.selected a{ /*selected main tab style */
background-image: url(images/shadeactive.gif);
color: #cc0000;
border-bottom-color: white;
}
I added the color to the li.selected a, but it works in FF not in IE5
.shadetabs li.selected a{ /*selected main tab style */
background-image: url(images/shadeactive.gif);
color: #cc0000;
border-bottom-color: white;
}
Love the tab menu option. Just curious how the tab can rotates once you click on the other choices? Can anyone help?
cheers,
cheers,
I love this Tabbed Menu....am hoping to use this with a Ajax content includer...which is also easy to use. What I need to figure out is how to automate the rotation of those tabs and their content...and pause that when people mouse over the content.
To get rid of the 1px problem, change
<code>
.shadetabs li.selected{
position: relative;
top: 1px;
}
<code>
to
<code>
.shadetabs li.selected{
position: relative;
top: 0px;
}
<code>
<code>
.shadetabs li.selected{
position: relative;
top: 1px;
}
<code>
to
<code>
.shadetabs li.selected{
position: relative;
top: 0px;
}
<code>
If you dont use the image and would like to change the color of the selected tab add this to the css code:
.shadetabs li.selected a:visited{
background-color:#FFFFFF;
text-decoration:none;
background-color:#FFFFFF;
font-weight:bold;
}
before this you only have (li.selected a:hover) which does not change the color of the selected tab before you hover over it. hope this help somebody out there let me now if it has please. also email bj396@hotmail.com
.shadetabs li.selected a:visited{
background-color:#FFFFFF;
text-decoration:none;
background-color:#FFFFFF;
font-weight:bold;
}
before this you only have (li.selected a:hover) which does not change the color of the selected tab before you hover over it. hope this help somebody out there let me now if it has please. also email bj396@hotmail.com









