sans-serif   serif

«

Triangles with CSS

January 13, 2010

I just discovered this:

Was goofing around in CSSEdit and saw a triangle on the screen and thought “how on earth?” … Of course, something like this must have been discovered before by others. Sure enough, developer Jon Rohan beat me to it. I still feel cool I stumbled on the trick independently!

And since this is a mootools blog I just can’t resist …

Related Posts:

  • No Related Posts

Comments

  • http://www.globacide.com Emilian Manolache

    Wow. Awesome! What browsers does this work on?

  • Henrik Hansen

    Actually, CSS triangles date back long ago. The are by some called “slants” and as I know, they were discovered by Eric Meyer. This a website that goes into a lot of details about “slants”: http://www.infimum.dk/HTML/slantinfo.html

  • http://meiocodigo.com Fábio M. Costa

    I don’t think ie6 can have transparent borders, can it?

  • Ryan Florence

    Nope, but you can set them to match the background color I suppose. The article I linked talks about using the chroma filter in IE6 to get it to treat a color as transparent.

  • http://dinnermint.org/ Jon rohan

    Yeah, I believe Henrik is correct, the technique was taught to me by a fellow developer, I just found very little documentation on this technique so I decided to write a blog post to share.

blog comments powered by Disqus

Comments RSS