Rounded Corners on Images using CSS

Posted Nov 26, 2008 // 1 comments
Laura:

Many of our clients want a photo to accompany almost every article on their site. Sometimes its necessary to offer some “styling” solutions to these photos, usually in the form of a CSS-driven frame around the photo.

One client wanted a photo styling treatment that mirrored the overall styling of their website: rounded corners on everything from header bars to buttons. We needed a simple way to add rounded corners to any photo on their site.

I was thrilled to find a simple solution that fit any size photo you could throw at it and works in IE! Also, even tho the original author claims you need javascript, this doesn’t seem to be the case.

Check it out here:
http://www.sitepoint.com/examples/rounded_images/css-only.php

About Laura

Laura Schoppa has over 10 years of professional experience as a designer, developing interfaces for websites and web-based applications, including information architecture and navigation design. She also has experience creating rich-media ...

more >

Read Laura's Blog

Comments

by Live Croupiers (not verified) on Thu, 06/25/2009 - 06:47

I’m currently working in a

I’m currently working in a .NET project (EPiServer CMS 5), and is faced with a design that uses the same kind of boxes all over the site. The boxes only differ by color and content, so things like shadows and rounded corners are clear repetition that I want to do only once. I’ll do the shadows and corners with CSS, but for that I need a couple of wrapper divs. Divs that I only want to specify once, and then reuse. /www.gratiscasinospielen.de

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
  • Allowed HTML tags: <a> <strong> <code> <p> <img> <ul> <ol> <li> <h2> <h3> <h4> <b> <u> <i>
  • You may insert videos with [video:URL]

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.