{"id":267,"date":"2013-05-24T06:27:55","date_gmt":"2013-05-24T06:27:55","guid":{"rendered":"http:\/\/theme.co\/x\/demo\/integrity\/10\/?page_id=267"},"modified":"2016-06-16T14:22:19","modified_gmt":"2016-06-16T14:22:19","slug":"clear","status":"publish","type":"page","link":"https:\/\/demo.theme.co\/ethos-1\/shortcodes\/clear\/","title":{"rendered":"Clear"},"content":{"rendered":"<h2  class=\"h-custom-headline h5 accent\" ><span>Without Clear<\/span><\/h2>\n<img  class=\"x-img x-img-thumbnail\" style=\"margin-bottom: 10px;\" src=\"\/\/theme.co\/media\/x-no-clear.png\" alt=\"Without Clear\">\n<p>The <code>&#091;clear&#093;<\/code> shortcode probably isn&#8217;t one you&#8217;ll have to use a whole lot, but it&#8217;s important to know when and where to use it. &#8220;Clearing&#8221; another element is most important when you begin floating elements on your page, for example, images. Problems can arise when the <em>last item in your content area<\/em> is floated to the left or the right to achieve the layout you&#8217;re looking to accomplish. When this happens, webpages tend to do some silly things, like the example seen above.<\/p>\n<h2  class=\"h-custom-headline h5 accent\" ><span>With Clear<\/span><\/h2>\n<img  class=\"x-img x-img-thumbnail\" style=\"margin-bottom: 10px;\" src=\"\/\/theme.co\/media\/x-with-clear.png\" alt=\"With Clear\">\n<p>In this second image, you can see that once we add the <code>&#091;clear&#093;<\/code> shortcode, everything is back in the right place again! If you find yourself running into layout problems when floating elements throughout your page, try the <code>&#091;clear&#093;<\/code> shortcode out to see if you can resolve your problems.<\/p>\n<p>You will also notice that although &#8220;invisible,&#8221; the <code>&#091;clear&#093;<\/code> shortcode allows you to input an ID, classes, or inline styles. This is because we use a hidden <code>&lt;hr&gt;<\/code> element to accomplish the clear by setting the border and margin to &#8220;0&#8221; (instead of nasty empty <code>&lt;div&gt;<\/code> elements that are a bad markup practice). If for any reason you would actually like to give this element a little style, feel free to do so!<\/p>\n<h2  class=\"h-custom-headline h5 accent\" ><span>Options<\/span><\/h2>\n<ul class=\"x-ul-icons\"  >\n<li class=\"x-li-icon\"  ><i class=\"x-icon-chevron-circle-right\" aria-hidden=\"true\" data-x-icon-s=\"&#xf138;\"  ><\/i><strong>id<\/strong>: add a unique ID to the shortcode.<\/li>\n<li class=\"x-li-icon\"  ><i class=\"x-icon-chevron-circle-right\" aria-hidden=\"true\" data-x-icon-s=\"&#xf138;\"  ><\/i><strong>class<\/strong>: add a class or multiple classes to the shortcode. <\/li>\n<li class=\"x-li-icon\"  ><i class=\"x-icon-chevron-circle-right\" aria-hidden=\"true\" data-x-icon-s=\"&#xf138;\"  ><\/i><strong>style<\/strong>: add inline styles to the shortcode.<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The &#091;clear&#093; shortcode probably isn&#8217;t one you&#8217;ll have to use a whole lot, but it&#8217;s important to know when and where to use it. &#8220;Clearing&#8221; another element is most important &#8230;<\/p>\n","protected":false},"author":16,"featured_media":0,"parent":259,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0},"_links":{"self":[{"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/pages\/267"}],"collection":[{"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/users\/16"}],"replies":[{"embeddable":true,"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/comments?post=267"}],"version-history":[{"count":2,"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/pages\/267\/revisions"}],"predecessor-version":[{"id":8583,"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/pages\/267\/revisions\/8583"}],"up":[{"embeddable":true,"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/pages\/259"}],"wp:attachment":[{"href":"https:\/\/demo.theme.co\/ethos-1\/wp-json\/wp\/v2\/media?parent=267"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}