the width of sidebar in wootheme

by Ilias
5 replies
  • WEB DESIGN
  • |
Does anyone know how to change the width of sidebar? i use canvas theme
if yes please explain to me how to do it and thanks in advance
#sidebar #width #wootheme
  • Profile picture of the author jbyte
    not familiar enough with that specific theme, but you can use firebug (firefox extention), right click on the sidebar to get the div id/class and then search for it in the css files.
    This assumes that you cannot change it in the admin settings for the theme.
    Signature

    I fix WordPress problems, PM me if you need help

    {{ DiscussionBoard.errors[8802946].message }}
    • Profile picture of the author rhinocl
      See if there is a file named sidebar.php in your theme. Read through it and change the width to your desired setting. Depending on how the theme is written that may mess up the rest of the display. (If it is fixed width you may have to reduce the width of the other parts which can be in a lot of places- header.php, index.php, single.php, category.php,archive.php and page.php).

      If you haven't done this before it will be better to pay someone a few dollars and have them send you a list of what files they changed. Then compare those files before and after and you can make the changes yourself next time.
      Generally you can't change sidebar widths just with css as the width is generated by php within the layout files. If you don't see it in sidebar.php, then you need to look at the include statements there.
      {{ DiscussionBoard.errors[8810285].message }}
      • Profile picture of the author Istvan Horvath
        This post is completely wrong in every sentence... nobody should pay attention. :rolleyes:



        Originally Posted by rhinocl View Post

        See if there is a file named sidebar.php in your theme. Read through it and change the width to your desired setting. Depending on how the theme is written that may mess up the rest of the display. (If it is fixed width you may have to reduce the width of the other parts which can be in a lot of places- header.php, index.php, single.php, category.php,archive.php and page.php).

        If you haven't done this before it will be better to pay someone a few dollars and have them send you a list of what files they changed. Then compare those files before and after and you can make the changes yourself next time.
        Generally you can't change sidebar widths just with css as the width is generated by php within the layout files. If you don't see it in sidebar.php, then you need to look at the include statements there.
        Signature

        {{ DiscussionBoard.errors[8810444].message }}
  • Profile picture of the author Istvan Horvath
    More regarding the post above ^^

    In every decent WP theme there is no style (CSS) declaration in the template files like sidebar.php. Which means, nobody can change the width of the sidebar by messing around with the PHP in that template file.

    The basic layout: overall width of the body, having inside the content area AND the sidebar, the width of those... and everything else is defined in the stylesheet of a theme.

    When wanting to change the width of the sidebar and you have to come here to ask basic questions... the best advice you could receive: don't try it. If you have to ask how to do it, you are not ready to do it.

    As a general idea: WP themes are built using divs and nested divs.
    There might be a general "wrapper" that keeps everything together; e.g. 900px.
    Inside there could be a content div (where you text goes) of 650px and a sidebar div next to it, of 250px, usually floated.
    Not counting borders, margins, padding etc. - just to makie it simple.

    If you alter the width of the sidebar (from 250 to 300), you also MUST change the width of the content to 600... so that the new sum 600+300 should be the same as the the overall width of the wrapper.

    However, you should be "fluent" in CSS to mess around with such a task!
    Signature

    {{ DiscussionBoard.errors[8810568].message }}
    • Profile picture of the author rhinocl
      Istvan is correct in that with a simple 1 sidebar theme you can control the sidebar width from style.css

      Many themes allow you to adjust it in the theme options and if that is the case you can control it there. If you need control past that point, such a theme will have the settings buried in layout files, or includes, functions or options.php

      Changing 1 sidebar in style.css is not that hard. You just need to make a practise blog with the same theme and play around with it there first.
      {{ DiscussionBoard.errors[8816067].message }}

Trending Topics