Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Centering layout

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 11-14-2008, 12:34 PM
 
ChrisP05 ChrisP05 is offline
 

Member
  
Join Date: Dec 2005
Posts: 13
 

Default Re: X-Cart 4.2 beta testing

Hi All.

Stupid question probably.

I just spent 3 hours trying to center the template in 4.2.

Tried this:

#page-container {
min-height: 100%;
position: relative;
width:980px;
}

which should have worked. It dont.

I want the template 980px wide centered on the screen.

Thanks,

Chris
__________________
Chris
X-Cart 4.4.1 Unix
Reply With Quote
  #2  
Old 11-14-2008, 12:37 PM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default Re: Centering layout

Moving this to its own thread. Use this:

#page-container {
min-height: 100%;
margin: 0 auto;
width:980px;
}
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 11-14-2008, 01:01 PM
 
ChrisP05 ChrisP05 is offline
 

Member
  
Join Date: Dec 2005
Posts: 13
 

Default Re: Centering layout

Thanks Balinor,

Almost worked.

Also have to take out some floats in #header #footer

/* page container */
#page-container {
min-height: 100%;
margin: 0 auto;
width:980px;
}

/* page layout */
#content-container {
clear: both;
float: left;
overflow: hidden;
position: relative;
width: 100%;
padding-bottom: 39px;
margin-top: 140px;
}
#content-container2 {
float: left;
position: relative;
right: 100%;
width: 200%;
}
#center {
float: left;
position: relative;
width: 50%;
left: 50%;
}
#left-bar {
float: left;
position: relative;
width: 150px;
margin-left: 7px;
}
#right-bar {
float: right;
right: 7px;
position: relative;
width: 158px;
}
#center-main {
margin: 0px 185px 0px 177px;
overflow: hidden;
position: relative;
}
#header {
height: 140px;
position: absolute;
top: 0;
width:980px;
}
#footer {
height: 39px;
width:980px;
position: absolute;
bottom: 0;
overflow: hidden;

}

/*
__________________
Chris
X-Cart 4.4.1 Unix
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 08:29 AM.

   

 
X-Cart forums © 2001-2020