How to position a div with left position against another div and right position at the edge of the screen?

I've made a demo for you, it should work. Tested on IE7/8/9, Firefox 4, Safari 5, Chrome 10 Cheers.

I've made a demo for you, it should work. Tested on IE7/8/9, Firefox 4, Safari 5, Chrome 10. Cheers.

I did it on this site a long time ago. I don't remember exactly how but I inspected the CSS and I think this is the necessary code. #menu-extend { background-color: #e8e8e8; float: right; height: 30px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: -30px; position: relative; right: 0px; top: 100px; width: 50%; z-index: 0; }.

Nice. I assume it works in IE6 too, which means it trumps my solution. – edeverett Apr 5 at 18:50.

You can absolutely position all edges of an element. So you could use a style rule to position the menu div something like this: . MenuDiv { top:50px; left:50%; padding-left:480px; margin-left:-480px; right:0px; position:absolute;} This won't work in IE6, so you'll need to to decide how, or if, you want to work around this.

Edit: Set the left hand position to 50% then use a negative margin and padding equal to half the wrapper div's width : jsfiddle.net/brddU/1/ (I'm assuming that the wrapper div is an independent div below the menu.

Unless I'm missing something of your intent, you can add two CSS rules: . LogoDiv {width:960;float:left} . MenuDiv {width:100%} And then have the following HTML: This is my logo code This is my menu code .

While the menu bar... Must have a infinite width to the RIGHT, no matter what size of the client screen. For both sides, we all know that width: 100% solves it quickly and sharply. But for just one side?

Another div, called top_menu_scrapper, which is absolute and basically, has just height, top and left alignment and background color. The JS captures the width of the user screen, takes off 960 (the size of the wrapper) resting just the both sides out of the wrapper. Since I only want it for one size, I split the value in half, and BAM, we get the correct size in pixels for the part of the screen I want to fill with.

It seemed perfect for me, but guess what, my boss said it is a kinda "bug-ish" because if the client loads the page in a small screen, and then maximize it without reload again, we'll see a big hole in the right side. Yes, my friends, for more weird that it sounds, this is exactly what he's complaining about. Anyway, so here I am, asking for a bit of your knowledge to aid my propose.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions