wright67uk Posted June 23, 2011 Share Posted June 23, 2011 Say for example I have three divs. Each of the divs 300px wide, all floating next to each other in a parent div (900px wide). Can I get these divs to stack on top of each other, if sombody reduces the window size of my site? Quote Link to comment Share on other sites More sharing options...
cssfreakie Posted June 24, 2011 Share Posted June 24, 2011 do you mean something like this? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <link type="text/css" rel="stylesheet" href="css/style.css" /> <title></title> <style type="text/css"> #wrapper{max-width: 900px} #wrapper div{width:298px; height:298px; border: 1px solid #eee;float:left;} </style> </head> <body> <div id="wrapper"> <div>a</div> <div>b</div> <div>c</div> </div> </body> </html> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.