Ian Young wrote:

> It is centring but not displaying properly in IE8 FF3.06 See
> http://www.iyesolutions.co.uk/templates/portfolios/template3/ for how
> the portal looks before we try the vertical align.

Yes, if you want to vertical-align #wrapper you must have a container
wrapped around it to declare 'display: table-cell' on.

One more div, like so...

<body>
        <div id="outerwrapper">
                <div id="wrapper">
        /* all elements inside wrapper */
                </div>
        </div>
</body>

body {display: table; height: 100%; width: 100%; text-align: center}
#outerwrapper {display: table-cell; vertical-align: middle;}
#wrapper {width:980px;background:#b0b0b0;margin:15px auto;}

-------------

My article describes "CSS table" (part of CSS 2/2.1) in action -
emulating HTML table rendering for regular, non-table elements. CSS
table is supported to near perfection by all new and most old browsers.
Only IE7 and older IE versions need additional hacks, as is also
described in my article.

        Georg
-- 
http://www.gunlaug.no
______________________________________________________________________
css-discuss [[email protected]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to