Centre align right hand column content

  • Unknown's avatar

    I’d like to centre the content in my right hand column.

    I managed to do so with my social buttons using:

    #social-networks ul {
    display: inline-block;
    }

    However I cannot figure out the CSS for the ‘Follow’ or ‘Categories’

    Also as the number of categories I use increases I’d like them split into two columns – if this possible?

    Many thanks!

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    a) Your social icons aren’t centered, because the ul has a default left margin. To really center them, turn the above code to this:

    #social-networks ul {
        display: inline-block;
        margin-left: 0;
    }

    And you can remove this addition, as it’s already present in the default CSS of the theme:

    #social-networks {
        text-align: center;
    }

    b) To center your other two widgets (as well as other similar widgets), you can add this:

    .widget ul li, .widget ol li, .widget p {
        text-align: center;
    }

    c) Yes it’s possible to split the category links into two columns. But it’s questionable: the sidebar in Adelle shrinks to adapt to different screen resolutions and mobile devices, so two columns will work only if all your category names are as short as your current ones. Anyway, to do it you’d start with this:

    #categories-2 ul li {
        display: inline-block;
        width: 48%;
    }

    Then you’ll need additional coding. What the additional coding will be depends on how you want to align each column, and you cannot really decide this when you only have two categories.

  • Unknown's avatar

    Oh, great. That’s perfect.
    Thank you so much.
    I’ll take your advice and leave splitting the category links until all 8 are in use.

  • The topic ‘Centre align right hand column content’ is closed to new replies.