2 new css tricks – Outline and Square Box!

I love learning new css tricks that solve layout problems. Creating a row of boxes that are squares at any size with a border. The trick is in the padding, this blog post led me in the right direction.

div {
width:25%;
height:0;
padding-bottom:25%;
outline:1px solid white;
}

That’ll do it! Eureka!

 
 
 
 


Leave a Reply

  • (will not be published)

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>