Skip to content

Instantly share code, notes, and snippets.

@xiaody
Created October 12, 2012 04:27
Show Gist options
  • Save xiaody/3877308 to your computer and use it in GitHub Desktop.
Save xiaody/3877308 to your computer and use it in GitHub Desktop.
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
section {
background:yellow;
}
#p1 {
background:blue;
width:50%;
float:right;
}
#div1 {
width:150px;
height:150px;
float:left;
background:red;
margin:20px;
}
#p2 {
clear:right;
margin:20px;
}
<!-- content to be placed inside <body>…</body> -->
<h1>Float Example</h1>
<section>
<div id=div1></div>
<p id=p1>Lorem ipsum dolor sit amet, </p>
<p id=p2>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
</section>
{"view":"split-vertical","fontsize":"100","seethrough":"","prefixfree":"1","page":"all"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment