• I tried to add an leader image to the header of each widget in the TwentyTen theme by adding this to the style.css;

    .widget-container h3 {
     background: grey url(images/sidetitle_bg.jpg) no-repeat top left;
     color: #B8AC16;
     line-height: 20px;
    }

    The colors do change, but no image.
    Please help..

Viewing 5 replies - 1 through 5 (of 5 total)
  • I also would like to know how to change the background of the widget titles to an image!

    .widget-container h3 {
     background: #CCCCCC url(images/sidetitle_bg.jpg) no-repeat;
     color: #B8AC16;
     line-height: 20px;
    }

    or

    .widget-container h3 {
     background: #CCCCCC url(images/sidetitle_bg.jpg) no-repeat top right;
     color: #B8AC16;
     line-height: 20px;
    }

    Try once

    What is the default css for the widget title styles and can I use it to add a background image to it?

    Also does it matter if I am using a sidebar generator plugin?

    I am using the twentyten theme as well.

    I am a bit of a beginner!

    Here is one of my pages:
    https://allsportsnewsonline.com/nfl/afc/afc-east/buffalo-bills/

    css file is style.css

    .widget h2.widgettitle{
     background: grey url(images/sidetitle_bg.jpg) no-repeat top left;
     color: #B8AC16;
     line-height: 20px;
    }

    default widget title css’s class name is widgettitle and widget calss is widget

    @axim30
    if you are still interested, please post a link to your site.

    @chinmoy
    you are referring to non-existing classes.

    @cafountain
    as it happens, your link does not have a sidebar; the only widgets are in the footer area.

    however, it would be the same css:

    h3.widget-title{
     background: grey url(https://allsportsnewsonline.com/wp-content/uploads/2010/07/SIDEBAR.gif) no-repeat top left;
     color: #B8AC16;
     line-height: 50px;
    }

    if you need to distinguish between the three major widget areas, you can use:

    for the top of the sidebar:
    #primary h3.widget-title{ ... }

    for the lower bit of the sidebar:
    #secondary h3.widget-title{ ... }

    for the footer widgets:
    #footer h3.widget-title{ ... }

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘How to add image to widget header TwentyTen’ is closed to new replies.