I've searched for: theme override, override layout, override template but I'm not having any luck.
If I have a 3 column layout, I have some pages that would be best displayed as a 2 column layout. I can remove the blocks from this page in the block settings, but how do I extend the main content page to then be over the block area?

-------------
| |..........| |

becomes
-------------
| |............|

Thanks

Comments

gjangelo’s picture

I'd recommend using the basic theme as a starting point for any theming project. http://drupal.org/project/basic

If you have already started, you can still grab helpful snippets of code from the basic theme, most notably..

<body class="<?php print $body_classes; ?>">

and the function that generates $body_classes -- it is in the theme's template.php.

When you put that in your theme, the body tag will have different classes on each page, like:

<body class="front not-logged-in page-videos no-sidebars with-navigation">

or

<body class="not-front not-logged-in page-node one-sidebar sidebar-right highlights">

And then you just put the sizes in the css, for example:

body.no-sidebars #maincontent {width:960px;}
body.one-sidebar #maincontent {width:760px;}
body.two-sidebars #maincontent {width:560px;}
bsmith451’s picture

Thank you!
That is incredibly helpful.