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

Internet Explorer centering everything

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #21  
Old 09-04-2007, 05:51 PM
 
balinor balinor is offline
 

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

Default Re: Internet Explorer centering everything

True, and if you want it even cleaner, use CSS:

.Container (margin: 0 auto;}
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #22  
Old 09-04-2007, 05:53 PM
 
OpheliaPayne OpheliaPayne is offline
 

Senior Member
  
Join Date: Aug 2007
Posts: 130
 

Default Re: Internet Explorer centering everything

Balinor,

I pasted the wrong code. Sorry about that. Lets try this again.

I changed this...

Code:
{* $Id: rectangle_top.tpl,v 1.25 2006/02/07 08:09:51 max Exp $ *} <center> <table class="Container" cellpadding="0" cellspacing="0" width="{$width|default:"90%"}"> <tr><td class="Container"> </center>

to this:

Code:
{* $Id: rectangle_top.tpl,v 1.25 2006/02/07 08:09:51 max Exp $ *} <table class="Container" cellpadding="0" cellspacing="0" width="{$width|default:"90%" align="center}"> <tr><td class="Container">

It does fix the issues of the tables being centered, however it creates a new issue where the the store is left aligned now instead of centered in the middle of the page. Since our site is centered in the middle of the page at 90%, we obviously can't have the store left aligned Any ideas on how to fix that?

carpeperdiem

I will try this with the css Thank you.
__________________
xCart 4.6.1
Reply With Quote
  #23  
Old 09-04-2007, 06:39 PM
 
Victoria Feemster Victoria Feemster is offline
 

Advanced Member
  
Join Date: Feb 2007
Posts: 45
 

Default Re: Internet Explorer centering everything

OpheliaPayne,

On your site, I see the text in the sideboxes as centered but your logo as right aligned on IE.
__________________
Thank you,
Victoria Feemster
x-cart pro - 4.1.8
Reply With Quote
  #24  
Old 09-04-2007, 07:25 PM
 
somekindahate somekindahate is offline
 

Advanced Member
  
Join Date: Apr 2007
Posts: 84
 

Default Re: Internet Explorer centering everything

OphelliaPayne,

Your solution of removing the <center> tag and using align="center" is not correct. And like others have stated, you should be using CSS to fix this problem, not deprecated HTML. Remove the align attribute and the center tags you've added.

Go to skin1/customer/main/home.tpl

After the <body> tag add <div id="envelope">
Before the closing </body> tag add </div>

Add the following to your CSS file skin1.css
Code:
body { text-align: center; } #envelope { text-align: left; margin: 0 auto; }

When you view the source, there should be a <div id="envelope"> ... </div> wrapping the contents of the page just inside of the body tag.
__________________
X-Cart Gold v. 4.1.10
Reply With Quote
  #25  
Old 09-04-2007, 08:17 PM
 
OpheliaPayne OpheliaPayne is offline
 

Senior Member
  
Join Date: Aug 2007
Posts: 130
 

Default Re: Internet Explorer centering everything

Quote:
Originally Posted by somekindahate
OphelliaPayne,

Your solution of removing the <center> tag and using align="center" is not correct. And like others have stated, you should be using CSS to fix this problem, not deprecated HTML. Remove the align attribute and the center tags you've added.

Go to skin1/customer/main/home.tpl

After the <body> tag add <div id="envelope">
Before the closing </body> tag add </div>

Add the following to your CSS file skin1.css
Code:
body { text-align: center; } #envelope { text-align: left; margin: 0 auto; }

When you view the source, there should be a <div id="envelope"> ... </div> wrapping the contents of the page just inside of the body tag.

This did not work.

Quote:
TABLE.Container { width: 900px; margin-left: auto; margin-right: auto; background-color: #FFFFFF; }

margin-left: auto;
margin-right: auto;

This did work. Thank you.
__________________
xCart 4.6.1
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 03:32 AM.

   

 
X-Cart forums © 2001-2020