css - How do I span two divs side-by-side for the full screen width? -


there lot of questions regarding side-by-side divs. didn't miss those. need spans whole width of screen. situation:

i need 3 divs positioned side-by-side. left, middle, , right divs we'll call them. middle div holds header contents of site , fixed width (800px). want left , right div span rest of screen width on either side. so..

<-left-> | middle | <- right ->

the reason want way because middle (content holding) div has backgrond gradient. let's left side of gradient white , right side black. need left div white continuation , right div black. way looks 1 fluid heading spans whole width of screen.

thanks.

a solution problem once implemented using 2 div elements, absolutely positioned, center div overlay. have working example here:

jsfiddle solution

this way, doesn't matter how wide screen is: div's span 50% of screen, , middle part behind centered div.

note might have use javascript workaround height-issues.


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -