Created
April 8, 2015 01:20
-
-
Save voidove/ed0903941cb94fb51fdc to your computer and use it in GitHub Desktop.
css float
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* css float | |
*/ | |
.container { | |
width: 150px; | |
height: 100px; | |
border: 1px solid blue; | |
} | |
.container .box{ | |
width: 50px; | |
border: 1px solid black; | |
margin: 5px; | |
float: left; | |
} | |
.clearleft { | |
clear: left; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="container"> | |
<div class="box"><span>1</span></div> | |
<div class="box clearleft"><span>2</span></div> | |
<div class="box"><span>3</span></div> | |
<div class="box"><span>4</span></div> | |
<div class="box"><span>5</span></div> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// alert('Hello world!'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"view":"separate","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