888888.888888.88""Yb..dP"Yb..8888b..Yb..dP.88b.88....db....8b....d8.88..dP""b8..dP"Y8
88__...88__...88__dP.dP...Yb..8I..Yb.YbdP..88Yb88...dPYb...88b..d88.88.dP...`".`Ybo."
88""...88""...88"Yb..Yb...dP..8I..dY..8P...88.Y88..dP__Yb..88YbdP88.88.Yb......o.`Y8b
88.....888888.88..Yb..YbodP..8888Y"..dP....88..Y8.dP""""Yb.88.YY.88.88..YboodP.8bodP'


88b.88.888888.888888.Yb........dP.dP"Yb..88""Yb.88..dP
88Yb88.88__.....88....Yb..db..dP.dP...Yb.88__dP.88odP.
88.Y88.88"".....88.....YbdPYbdP..Yb...dP.88"Yb..88"Yb.
88..Y8.888888...88......YP..YP....YbodP..88..Yb.88..Yb

February 27, 2010

My most popular plugin is Fun with Sidebar Tabs and it is easy to see why: it provides functionality that is much in demand. For that reason I have decided to devote a few posts to looking at alternative ways of styling the tabs to help users fit it to their theme more readily.

For the first post I am going to use this site as an example; I use Fun with Sidebar Tabs for the tabbed box on the home page.

I have am using the default WordPress theme and starting with a tabbed sidebar using the default settings.

To change the styling I am only going to use the widget options. To access these click edit on the sidebar widget. There are five blocks of CSS in these options labelled:

The first change is to create the background for the tabs. For this I will change the CSS in the first box (Amend the position of the tabs). I will add four lines:

background-color:black;
width:1989px;
height:24px;

This alters the sidebar to look like this:

The next change is to Overide the Tabs CSS. Change:

font-size:10px;
line-height:1;
font-family:Arial, Helvetica, sans-serif;
color:#000;
padding:5px;
border:1px solid #ccc;
background-color:#eee;

To:

font-size:12px;
line-height:1;
font-family:Arial, Helvetica, sans-serif;
color:#fff;
padding:6px;
background-color:#000;

This increases the text size, removes a border, and increases the padding to compensate, in order to make the tabs the same height as the background. The background colour is changed to the same colour as the background and the text changed to white.

You also need to alter The Selected Tab from:

border-bottom:1px solid #fff;
background-color:#fff;

To:

background-color:red;

The effect of these change is a tabbed sidebar that looks like this:

The last change is to resolve the problem with the image above. The hovered over tab hides the text, so you can change the CSS for Tabs Hovered Over to:

background-color:#660000;

I will leave you to discover impact of this final change.

This CSS pretty much describes the CSS used on this blog, but with one exception. Instead of the background colours I have used the images shown below.

Grey Fade

Colour Fade

If you use the Fun with Sidebar Tabs plugin and have modified the styling then please leave a comment. I don’t get to see many examples of it in use and I would love to see more.

Updating Code Snippets Here
Wordpress fun?
one comment
page 1338
Why I Ditched Disqus
Disqus email?
5 comments
page 1175
Html 5 Gallery
Themeatic html5?
6 comments
page 1305
Premium Ithemes Review Photo Gallery
Ithemes review?
4 comments
page 226
Updating Code Snippets Here
Wordpress fun plugins?
one comment
page 1338
Post Image The Easy Peasy Way
Wordpress first image?
26 comments
page 1065
Quick N Dirty Admin Login Screen
login screen using css?
no comment
page 128
Html 5 Gallery
Picture gallery html5?
6 comments
page 1305
Post Image The Easy Peasy Way
Wordpress first image gallery?
26 comments
page 1065
Post Image The Easy Peasy Way
Resizing images in thecontent?
26 comments
page 1065
Html 5 Gallery
Html 5 photo gallery?
6 comments
page 1305
Dont Mess With My Toot Toot
Wordpress custom content?
16 comments
page 599
Post Image The Easy Peasy Way
Inserting an image url in comments?
26 comments
page 1065
Post Image The Easy Peasy Way
Wp attachment functions?
26 comments
page 1065
Using Your Own Url Shortener
String shortner?
4 comments
page 1190
Quick N Dirty Admin Login Screen
My admin login page?
no comment
page 128
Using Your Own Url Shortener
How to build a shortner link?
4 comments
page 1190
Post Image The Easy Peasy Way
Get post attacments?
26 comments
page 1065
Theming Habari Vs Wordpress
Habari vs wordpress?
13 comments
page 440
Upload From Url
Upload to url?
6 comments
page 326
Are Child Themes The Best Option
Wp child themes?
15 comments
page 1262
Silence Is Golden
Silence is golden wordpress?
3 comments
page 213
How To Add Sidebars To A Theme
Html hot add a side bar?
10 comments
page 1053
How To Add Sidebars To A Theme
How to add picture to the wordpress sidebar on sidebarphp?
10 comments
page 1053
Fun With Sidebar Tabs Styling
Position of the tabs thematic?
2 comments
page 336
Using Your Own Url Shortener
Short url?
4 comments
page 1190
Why I Ditched Disqus
Styling disqus widgets?
5 comments
page 1175
Wordpress 25 Exif Fields
Wordpress exif?
12 comments
page 230
Dont Mess With My Toot Toot
Fun with toots?
16 comments
page 599
Dont Mess With My Toot Toot
Fun with toots?
16 comments
page 599
Html 5 Gallery
Html 5 gallery?
6 comments
page 1305
Converting Wordpress Themes To Habari
Habari timthumb?
one comment
page 694
Wordpress 25 Exif Fields
Habari timthumb?
12 comments
page 230
  1 query every 1817 seconds, updated 1 seconds ago.
Monday, 5pm
 __
(__)
   `

 Andrew Rickmann

It wouldn't be easy. To be honest there are probably better ways of going about that.

You might like to try the replacement for this plugin; http://www.wp-fun.co.uk/fun-with-widget-structu... this has more options that would help but it is all really down to creating the right CSS to get it to work.

Monday, 12am
 __
(__)
   `

 Glenn

Great little tute! Is there an easy way to have the tabs vertical? e.g. hang off over the edge of the sidebar over the background?

that'd be awesome!