I'm not exactly sure what you end goal is so let me know if I'm
assuming wrong, but you want to relatively position your main content
(centered), but you are absolutely positioning your nav dropdowns?
Is your nav inside the content box div? If not, then yeah it's going
to get misaligned.
I also don't see the need for javascript to do the positioning unless
you are centering vertically as well. If you are doing vertical
centering, I'm, not sure doc.write is the best way though. You could
simply adjust the height style with javascript.

If you are just positioning horizontally, why not make a 100%/100%
div, do a div aligned center for your content, and absolutely position
your nav div inside that? then you have total control of where it
goes, and it will stay aligned with the content div.

I did a little example in case my explanation makes so sense, and I
love playing around with designs late at night, or morning as the case
may be.

<style type="text/css">
div#container {
        height: 100%;
        width: 100%;
        top: 0px;
        left: 0px;
        background-color: black;
        //could use text-align: center here instead of
        //align="center" in the tag.
}

div#content {
        height: 500px;
        width: 777px;
        top: 0px;
        background-color: white;
        position: relative;
}

div#nav {
        position: absolute;
        top: 0px;
        left: 0px;
        height:20px;
        width: 100%;
        background-color: green;
        // Total control over positioning of nav since it's absolute
}

body {
        margin: 0px;
}
</style>

<div id="container" align="center">
        <div id="content">
                <div id="nav">Stick Heirmenus in here</div>
        </div>
</div>

this will not look right in ns4 without some tweaking.


-- 
jon
mailto:[EMAIL PROTECTED]

Friday, August 2, 2002, 3:41:37 AM, you wrote:

IV> Hi

IV> I wish to center my tables if the screen resolution is above 800x600,
IV> if it is 800x600 it will be a full screen,  based using

IV> <div style="position: absolute; left: 1; top: 0;  777; id="logooo">

IV> and the javascript file below, all this works, apart from one thing, I
IV> am using HierMenus, using pixel positioning for the position of the
IV> drop downs.  ..e.g  however these are all out of alignment when I am
IV> using the above div to center the table.

IV> Has anybody on this list seen anything like this before, and any
IV> ideas for a solution?

______________________________________________________________________
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to