Note that there are some explanatory texts on larger screens.

plurals
  1. PO3 Flexible divs inside a flexible parent div
    primarykey
    data
    text
    <p>I am trying to get 3 flexible images to line up horizontally and stay within the confines of their flexible div container which has a flexible background,</p> <p>the background of the container and the 3 images should all stay in relation to each other positionally so they are always on top of each other. they should get larger and smaller with the size of the browser window but not exceed 800 px in width. </p> <p>The problem I am having is the background and footer slam to the left and the button divs go right.</p> <p><a href="http://jsfiddle.net/trapline/ZBJPF/2/" rel="nofollow">My JSFIDDLE</a></p> <p>HTML:</p> <pre><code>&lt;div id="container"&gt; &lt;div id="footer"&gt; &lt;div id="left"&gt; &lt;input type="image" name="MyLeftButton" id="MyLeftButton" class="imgstretch" src="Images/MyLeftImage.png" style="border-width:0px;"&gt; &lt;/div&gt; &lt;div id="middle"&gt; &lt;input type="image" name="MyMiddleButton" id="MyMiddleButton" class="imgstretch" src="Images/MyMiddleImage.png" style="border-width:0px;"&gt; &lt;/div&gt; &lt;div id="right"&gt; &lt;input type="image" name="MyRightButton" id="MyRightButton" class="imgstretch" src="Images/MyRightImage.png" style="border-width:0px;"&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; </code></pre> <p>CSS:</p> <pre><code>#container { margin: 0em auto 0em auto; width: 100%; max-width: 800px; } #footer { width: 100%; max-width: 800px; max-height: 80px; float: left; text-align: center; position: fixed; bottom: 0em; background-color: #009FC1; } #left { float: left; max-height: 80px; max-width: 294px; width: 36%; margin-left: 20px; display: inline-block; background-color: #CCCCCC; } #middle { max-height: 80px; width: 25%; float: left; max-width: 202px; display: inline-block; background-color: #889FC1; } #right { max-height: 80px; max-width: 294px; width: 36%; float: left; display: inline-block; background-color: #9999DD; } .imgstretch { width:100%; } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload