Hi,

The current Marinelli theme has two 195px sidebars. I would be ever so grateful if someone could assist me with changing these sidebars from two sidebars to one large sidebar preferably 300px or 350px?

Any help is appreciated.

Thank you!

Comments

shruti.sheth’s picture

Hello,
The following can be the one of the ways of achieving the layout requirement as per mentioned above.
Steps to perform :
1. Remove " 'right' => 'Right sidebar', "the from the following code in your modules/system/system.module

function system_theme_default() {
return array(
'regions' => array(
'left' => 'Left sidebar',
'right' => 'Right sidebar',
'content' => 'Content',
'header' => 'Header',
'footer' => 'Footer',
),

2. In your layout.css file
change the width in the following code from 180px to 300px

.lsidebar { 
	width: 180px;
	float: left;
	margin-top:0px;
	margin-right:0px;
	margin-bottom:0px;
	margin-left:15px;
	}

3. Also add the property 'width' to the #primary, to give appropriate width to it, in layout.css, so the code looks as follows

#primary {
        width: 625px !important;
	float: left;
	margin: 0px;
	/*larghezza settata nel file template.php -  width set in template.php*/
	}

I hope this proves helpful.

prajaktam’s picture

Hello,
@HS
I have enabled and configured the marinelli (version-marinelli-6.x-2.9) theme on my test site. To change two sidebars to one large sidebar instead of making changes in system module you can override your marinelli theme. Since the default settings for theme regions in system module is applied to all the themes for which the regions are not defined in their particular info files. So what I will suggest is you override the marinelli.info file and other related files to reflect the changes. So to start with
1) You need to declare the regions in marinelli.info file. Add the following code below the line stylesheets[all][] = links.css

regions[left] = Left Sidebar
regions[header] = header
regions[content] = content
regions[footer] = footer

(I am keeping the left sidebar and removing the right sidebar) Clear the cache at admin/settings/performance and go to the admin/build/block page you will see that the right sidebar is removed from the regions. Now enable the required blocks in left sidebar.

2) Open up the template.php file. Replace

function marinelli_width($left, $right) {
  $width = 550;
  if (!$left ) {
    $width = $width +195;
  }  
  
   if (!$right) {
    $width = $width +195;
  }
  return $width;
}

With

function marinelli_width($left) {
  $width = 550;
  if (!$left ) {
    $width = $width +387;
  }
  return $width;
}

3) In page.tpl.php file, Replace
<div id="primary" style=<?php print '"width:'.marinelli_width( $left, $right).'px;">' ?>
this line with
<div id="primary" style=<?php print '"width:'.marinelli_width( $left).'px;">' ?>

4) Now to set the width of 350px to leftsidebar, open up the layout.css file and replace
.lsidebar {
width: 180px;
float: left;
margin-top:0px;
margin-right:0px;
margin-bottom:0px;
margin-left:15px;
}

this css with,
.lsidebar {
width: 350px;
float: left;
margin-top:0px;
margin-right:0px;
margin-bottom:0px;
margin-left:15px;
}

5) Please make sure to clear the cache at admin/settings/performance

Thanks,
Prajakta

oadaeh’s picture

Issue summary: View changes
Status: Active » Closed (won't fix)

This issue is being closed because it is against a branch for a version of Drupal that is no longer supported.
If you feel that this issue is still valid, feel free to re-open and update it (and any possible patch) to work with the 7.x-4.x branch.
Thank you.