Zen Cart Logo
Forums / Addon Templates / How do I resize center column when left and/or right sidebars are disabled?

How do I resize center column when left and/or right sidebars are disabled?

Locked

Views: 2,923

Results 1 to 9 of 9
This thread is locked. New replies are disabled.
5 Jul 2009, 3:44 AM
#1
dmm2020 avatar

dmm2020

Zen Follower

Join Date:
Feb 2009
Posts:
157
Plugin Contributions:
0

How do I resize center column when left and/or right sidebars are disabled?

How do I force my center column to full width when left and right sidebars get disabled?

For reference take a look at the news blog I am working on.

5 Jul 2009, 4:12 AM
#2
tat2nu avatar

tat2nu

Zen Follower

Join Date:
Jan 2005
Posts:
178
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

configuration>layout settings then column right status-global and column left status-global

Set the columns that you are not using to '0'

Marc

5 Jul 2009, 4:37 AM
#3
dmm2020 avatar

dmm2020

Zen Follower

Join Date:
Feb 2009
Posts:
157
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

tat2nu:

configuration>layout settings then column right status-global and column left status-global

Set the columns that you are not using to '0'

Marc

Explain please. I do not understand what you are talking about. Below is the code I am using to hide the side columns:

if (in_array($current_page_base,explode(",",'wordpress')) ) {
    $flag_disable_right = true;
	 
	
  }

I found a theme that seems to work for wordpress to display from center to right column. So issue is kind of moot now, but I want to get educated on this, so if I need it in the future I know how.

What I want to do is add something after that line that disables the right column, to force center column to resize to occupy space that right column used to have. Or if both right and left columns are disabled then the center column to go to full width.

5 Jul 2009, 5:11 AM
#4
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,606
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

Which template is that? Have you looked at the support thread for it?

5 Jul 2009, 3:04 PM
#5
tat2nu avatar

tat2nu

Zen Follower

Join Date:
Jan 2005
Posts:
178
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

From the admin page look under the 'Configuration' tab then scroll down and click the 'Layout Settings' button.

In the 'layout settings' page look down and you can control your right and left columns there with 'Column Right Status - Global' and 'Column Left Status- Global'. When the column are turned off here then they allow the 'Center Column' to take up that space.

Marc

6 Jul 2009, 4:19 AM
#6
dmm2020 avatar

dmm2020

Zen Follower

Join Date:
Feb 2009
Posts:
157
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

Kim:

Which template is that? Have you looked at the support thread for it?

Yeah I looked at the thread for it. Problem is it's in bits and pieces and a nightmare to even attempt to piece it all together. I spent 2 days of vacation doing nothing but researchin pieces of forum thread on that issue and got no where.

As far as the URL to see what I am talkinga bout look at http://news.arcademprosoftware.com

I also bought that manual a couple years ago, but can't find nothing in it on forcing the center to resize when I turn the columns off on the fly.

6 Jul 2009, 4:22 AM
#7
dmm2020 avatar

dmm2020

Zen Follower

Join Date:
Feb 2009
Posts:
157
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

tat2nu:

From the admin page look under the 'Configuration' tab then scroll down and click the 'Layout Settings' button.

In the 'layout settings' page look down and you can control your right and left columns there with 'Column Right Status - Global' and 'Column Left Status- Global'. When the column are turned off here then they allow the 'Center Column' to take up that space.

Marc

THis will not work because those settings are GLOBAL. I do not want the side columns turned off globally at all.

The problem is as you see in my prior post, when I turn off the left and/or right columns the center column does not resize automatically, least not with wordpress.

6 Jul 2009, 11:25 AM
#8
tat2nu avatar

tat2nu

Zen Follower

Join Date:
Jan 2005
Posts:
178
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

From what I have learned is that they are either 'on' or 'off' globally. You can have pages with nothing in the column but the column will still be there. This fixes your column alignment issue in stylesheeet.css

.outer {
    padding-left: 197px; /* Same width as margin-left for the float-wrap div */
    padding-right: 182px; /* Our right column width */
}
.inner {
    width: 100%;
}
.float-wrap {
    float: left;
    width: 97%;
    margin-left: -197px; /* Same length as .outer padding-left but with negative value */
}
#content {
    float: right;
    margin-right: -197px; /* Same length as .outer padding-left but with negative value */
    width: 100%;
    line-height:1.6;
    position: relative; /* IE needs this  */
}
.contentWrap {
    padding: 5px 0 5px 5px;
}
#navColumnOne {
    float: left;
    position: relative; /* IE needs this  */
}
#navColumnTwo {
    float: right;
    margin-right: -182px; /* This negative margin-right value is in this example the same as the right column width. */
    position: relative; /* IE needs this  */
}
* html #navColumnTwo {
    margin-right: -202px !important; /* Fixes IE6 Issue */
}
/* end wrappers - page or section containers*/

Post in the Cherry_Zen template thread and see if there is a solution to get the center box to expand in the absence of a sidebox. The link is here:

http://www.zen-cart.com/forum/showthread.php?t=72703

Marc

8 Jul 2009, 11:39 AM
#9
justdoitrocky avatar

justdoitrocky

New Zenner

Join Date:
Apr 2009
Posts:
13
Plugin Contributions:
0

Re: How do I resize center column when left and/or right sidebars are disabled?

Thanks, I got it. :bigups: