Support » Themes and Templates » How to center text from the list in my sidebar?

  • Ok guys.I know that this is a often asked question here in the forum but as it’s theme related i really didn’t succeed to fix it in my situation.
    Here is my website under construction.
    The problem i have is the one with the sidebar on the right.
    The one with the “Categories; Archives; Search; Meta; Calendar” list.
    I want to align these names in the center of the “shelfs” but i really don`t have an idea anymore after all these tries.
    I am using a child theme with a custom style.css.
    The last thing i tried was adding this to the css:

    #sidebar_1 ul{
    padding: 62px 30px 28px 30px;


    And also:

    .sidebar_1 ul{
    padding: 62px 30px 28px 30px;


    Any idea how to fix this?

Viewing 10 replies - 1 through 10 (of 10 total)
  • esmi


    Forum Moderator

    Try using Firefox with the Firebug add-on for this kind of CSS troubleshooting. Or use whatever developer tool is available in your web browser.

    Yes indeed I used Firebug for this and managed to fix it in the center but only trough the html but since I’m using a child theme I was thinking if there is some way for accomplish this by modifying only the custom CSS?
    I can modify the html but I’m afraid of the possible theme update.

    With Firebug if you disable/hide the 3 background images of the sidebar a block will appear around the “Categories”, which when selected appears outside the CSS.Here i can set the padding like above and the list gets centered, but this is done only in live mode.
    In the CSS I had no luck.

    Hey Cevi,

    Can you try this custom CSS code?

    #sidebar_1 h2 {
    background: url(images/sidebar01_title_bg2.jpg) no-repeat bottom;
    height: 13px;
    width: 229px;
    padding: 0 0 30px 0;
    margin-top: 40px;
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    tex-align: center;
    color: #8f8d8d;
    float: left;

    Thanks my friend, this did the job. 🙂
    They are all centered now except the first one “Categories” which stands with right alignment.
    Is it maybe that its not in the h2 section?

    Not exactly, it’s because you have defined a different styles for the first widget. You can try with this code:

    #sidebar_1 .widget_1 h2 {
    background: url(images/sidebar01_title_bg1.jpg) no-repeat center bottom;
    padding:62px 0 28px 0;

    It’s seems to work 🙂

    Yess, job done. 🙂
    Only if i can take the “Categories” text 1-2px up to be the same as the others and that will be the thing.
    Anyway thank you a lot for your effort. 🙂

    You’re welcome

    I know that is not possible to delete class from css but i know that it can be set to hidden.
    There is a text “Categories” in the .Categories class that i want to be removed or hidden.
    I’ve tried to manage this but with no luck.
    All i want to do is to center align all the items on the sidebar and remove or hide that “Categories” text under the first “shelf” and above the “fruits” category.
    Something similar to this:

    Categories -> removed or hidden

    March 2014

    “The search bar”

    Site Admin

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘How to center text from the list in my sidebar?’ is closed to new replies.