0.12 page width

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Locked
KevinK

0.12 page width

Post by KevinK »

At the risk of making myself sound like a complete idiot (which I know I am not but I cannot figure this out and wasn't it said somewhere here that there is no such thing as a "stupid question???), I have a "stupid" question.

I notice that the 0.12 version as installed has a variable page width (which I like) but for me it seems to stop at 1024 width. The question I have is how does it stop getting wider at the 1024 width? I cannot see this anywhere in the source...
jelle

Re: 0.12 page width

Post by jelle »

What template and css are you talking about? Most  likely it's somewhere in the css, as layout details do not belong in the html, but to let somebody else find it for you you'll have to tell 'em where to look first.
KevinK

Re: 0.12 page width

Post by KevinK »

Sorry if I was unclear.

I install the package 0.12 and looking at the main (home) page, there is a variable width. On the initial install, before any changes, the HOME page uses "Bulletmenu Vert 1 col" template. I have looked in all of the templates and css files I thought are being used on the HOME page. I also viewed source of this page and got the CSS file address and printed it out so I could look aat the complete CSS file. Nowhere do I see a NUMERIC value for the page width. I see 70% for the div#main and 25% for the div#menu_vert - so I am guessing that it is a function of these values.

I am not trying to get someone else to find it for me, I am hoping that someone can point me in the right direction so I can look and understand how it is being done before I start customizing the code.
Last edited by KevinK on Fri Mar 10, 2006 6:54 pm, edited 1 time in total.
jelle

Re: 0.12 page width

Post by jelle »

are you using IE? then this snippet may interest you:

Code: Select all

unction P7_MinMaxW(a,b){
	var nw="auto",w=document.documentElement.clientWidth;
	if(w>=b){nw=b+"px";}if(w<=a){nw=a+"px";}return nw;
}
//-->
</__script>
<!--[if lte IE 6]>
<style type="text/css">
#pagewrapper {width:expression(P7_MinMaxW(720,950));}
#container {height: 1%;}
</style>
<![endif]-->
There are some absolute values in there...
KevinK

Re: 0.12 page width

Post by KevinK »

No I am not using IE but I did somehow miss that code, thank you.
westis

Re: 0.12 page width

Post by westis »

KevinK,

Look in the stylesheet called "Layout" for this section:

    div#pagewrapper {
        margin: 0 auto;
        max-width: 80em;
        min-width: 60em;
        padding: 0;
        text-align: left;
    }


The max-width for non-IE browsers is 80em, that is it is relative to the font size (try increasing/decreasing the font size in the browser). The body font size is set in the "Typography" stylesheet, so 80em (and 60em for min-width) is relative to the font size that is set there.

As IE is not smart enough to understand min-width and max-width it instead uses the JavaScript that jelle referred to to achieve the same purpose of setting min- and max-width.

Hope that helps.
Locked

Return to “CMSMS Core”