{"id":149,"date":"2017-04-11T20:01:25","date_gmt":"2017-04-11T20:01:25","guid":{"rendered":"http:\/\/mansavageproductions.com\/websitesvideos\/?p=149"},"modified":"2017-04-11T22:53:19","modified_gmt":"2017-04-11T22:53:19","slug":"how-to-float-3-divs-side-by-side","status":"publish","type":"post","link":"http:\/\/mansavageproductions.com\/websitesvideos\/2017\/04\/11\/how-to-float-3-divs-side-by-side\/","title":{"rendered":"How to float 3 divs side by side."},"content":{"rendered":"<p>The modern way is using the CSS3 <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/CSS\/CSS_Flexible_Box_Layout\/Using_CSS_flexible_boxes\" rel=\"noreferrer\"><strong><u><span style=\"color: #0066cc;\">flexbox<\/span><\/u><\/strong><\/a><\/p>\n<p>Put the following into the .css file:<\/p>\n<p><span class=\"pun\">.<\/span><span class=\"pln\">container <\/span><span class=\"pun\">{<\/span><br \/>\n<span class=\"kwd\">display<\/span><span class=\"pun\">:<\/span><span class=\"pln\"> flex<\/span><span class=\"pun\">;<\/span><br \/>\n<span class=\"pun\">}<\/span> <span class=\"pun\">.<\/span><span class=\"pln\">container <\/span><span class=\"pun\">&gt;<\/span><span class=\"pln\"> div <\/span><span class=\"pun\">{<\/span><br \/>\n<span class=\"kwd\">flex<\/span><span class=\"pun\">:<\/span> <span class=\"lit\">1<\/span><span class=\"pun\">;<\/span> <span class=\"com\">\/*grow*\/<\/span><br \/>\n<span class=\"pun\">}<\/span><\/p>\n<p>Put the following into the page code:<\/p>\n<p><span class=\"tag\">&lt;div<\/span> <span class=\"atn\">class<\/span><span class=\"pun\">=<\/span><span class=\"atv\">&#8220;container&#8221;<\/span><span class=\"tag\">&gt;<\/span><br \/>\n<span class=\"tag\">&lt;div&gt;<\/span><span class=\"pln\">Left div<\/span><span class=\"tag\">&lt;\/div&gt;<\/span><br \/>\n<span class=\"tag\">&lt;div&gt;<\/span><span class=\"pln\">Middle div<\/span><span class=\"tag\">&lt;\/div&gt;<\/span><br \/>\n<span class=\"tag\">&lt;div&gt;<\/span><span class=\"pln\">Right div<\/span><span class=\"tag\">&lt;\/div&gt;<\/span><br \/>\n<span class=\"tag\">&lt;\/div&gt;<\/span><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The modern way is using the CSS3 flexbox Put the following into the .css file: .container { display: flex; } .container &gt; div { flex: 1; \/*grow*\/ } Put the following into the page code: &lt;div class=&#8220;container&#8221;&gt; &lt;div&gt;Left div&lt;\/div&gt; &lt;div&gt;Middle div&lt;\/div&gt; &lt;div&gt;Right div&lt;\/div&gt; &lt;\/div&gt; &nbsp;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-149","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/posts\/149","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/comments?post=149"}],"version-history":[{"count":4,"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/posts\/149\/revisions"}],"predecessor-version":[{"id":153,"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/posts\/149\/revisions\/153"}],"wp:attachment":[{"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/media?parent=149"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/categories?post=149"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/mansavageproductions.com\/websitesvideos\/wp-json\/wp\/v2\/tags?post=149"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}