The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Home › Forums › CSS › CREATING A CSS CIRCLE.
Whats the cleanest and simplest way of creating a circle in CSS and then centering a smaller image?
Here’s what I have so far.
#circle { width: 200px; height: 200px; -webkit-border-radius: 200px; -moz-border-radius: 200px; border-radius: 200px; background-color: #333; }
Thanks,
:)
I think Chris did something like this in codepen.
border-radius: 50%;
This should about cover it. (expanding upon HugoGiraudel’s exhaustive post) <3
http://codepen.io/anon/pen/pEeij
I took the time to use <code> and <pre> tags. :P
<code>
<pre>