Center Page

How and where can I adjust the page to center only? Because as of right now all my pages are at 100%. I just want to fit on the center of the screen.

Thanks

[quote name=‘poloxstar’]How and where can I adjust the page to center only? Because as of right now all my pages are at 100%. I just want to fit on the center of the screen.

Thanks[/QUOTE]



Poloxstar



Which version are you using and what skin are you also using.



Typically in the index.tpl file you can adjust the overall table width if you want to center the look as well as setting the alignment - but you have to be careful as some images and other files are width based and may have some effect on the visual appearance.



hope this helps

In version 1.3.5 you can change this in:



skins/yourskin/customer/styles.css



It should be around line 14 and look like:


body {
background-color: #ffffff;
min-width: 910px;
}




I changed mine to look like this:


body {
background-color: #c0bc91;
min-width: 910px;
align: center;
width: 90%;
margin-left: 5%;
margin-right: 5%;

}




Hope this helped.



Brandon

[quote name=‘brandonvd’]In version 1.3.5 you can change this in:



skins/yourskin/customer/styles.css



It should be around line 14 and look like:


body {
background-color: #ffffff;
min-width: 910px;
}




I changed mine to look like this:


body {
background-color: #c0bc91;
min-width: 910px;
align: center;
width: 90%;
margin-left: 5%;
margin-right: 5%;

}




Hope this helped.



Brandon[/QUOTE]



Problem with this is it stretches to the widths of different monitors. I’m looking to do the same thing, but I need to FIX the width and have it centered. I’ve tried throwing DIV tags into the index.tpl file, but there are too many other CSS codes that I think it’s counter-acting the center DIV tag. Is there another way to center the entire store with a fixed width?

I spoke too soon…

If anyone else is running into the same problem as me, check this out: [url]http://forum.cs-cart.com/showpost.php?p=21559&postcount=1[/url]



It did the trick!

The problem with the way i did it in that post mean’t that if the page was not fully maximized the vmenu would not sit correctly, i’ve now used the following method which works:



In style.css add the following:


div#wrapper {
position:relative;
margin-left:auto;
margin-right:auto;
top: 0px;
width:950px; /* set to required site width */
background-color: #ffffff;
}




and in index.tpl addthe red parts below:

```php


[COLOR="Red"]
[/COLOR]

{if 'SKINS_PANEL'|defined}
{include file="demo_skin_selector.tpl"}
{/if}

{* http://blog.html.it/layoutgala/LayoutGala14.html *}
{include file="top.tpl"}

{include file="main.tpl"}
{include file="bottom.tpl"}

{include file="common_templates/loading_box.tpl"}

[COLOR="red"]
[/COLOR]

```

Ah - I’ll have to try that one out too. Thanks!

Thanks Charlie,



I was having the same problem. If you centered the page and used emenu and then changed the size of the window the menu would just hang out there. This fixed it!