What you want to see on DotNetFunda.com ?
Go to DotNetFunda.com
Twitter TwitterLinkedIn
YouTubeGoogle
 Online : 4314 |  Welcome, Guest!   Register  Login
Home > Articles > CSS > Creating a circle with CSS

Creating a circle with CSS

1 vote(s)
Rating: 5 out of 5
Article posted by Dotnetrajanikanth on 4/20/2012 | Views: 4939 | Category: CSS | Level: Beginner | Points: 250 red flag


Here i am going to teach you a very nice and cool css effect. Creating circles with css. Is it that amazing. I have tested it in mozilla firefox and chrome browsers. and it works fine.

Introduction

Creating a circle in CSS3. This is pretty awesome write... and its simple too. Anybody who knows basic css can do this. hope every one will try this.



Objective

Objective of this article is to create a circle with css



Using the code

First thing is that you need to create a division in your webpage. Just using the <div>
<div>
Circle


</div>
Next is our css
The css is so simple. we are going to use the border-radius property in css3.

Note: the height and width should be equal.
.circle {
  border-radius: 50%;
  background-color:Black;
  width: 200px;
  height: 200px;
}
Now jus add the css class

<div class="circle">
Circle


</div>
The circel is ready.

Conclusion

so jus think how easy this thing is. Hope this will help the web designers out here.

Happy Coding

If you like this article, subscribe to our RSS Feed. You can also subscribe via email to our Interview Questions, Codes and Forums section.

Page copy protected against web site content infringement by Copyscape
Found interesting? Add this to:



Please Sign In to vote for this post.

Latest Articles from Dotnetrajanikanth

About Rohith Gopi

Experience:1 year(s)
Home page:http://www.dotnetfunda.com
Member since:Wednesday, April 18, 2012
Level:Starter
Status: [Member]
Biography:
 Responses
Posted by: Dotnetrajanikanth | Posted on: 23 Apr 2012 07:06:13 AM | Points: 25

Dear Readers,

I want to add one more thing. If you want to make an ellipse using css3 jus change the height and width make the height and width unequal... you will get ellipse.

Enjoy !!!

>> Write Response - Respond to this post and get points
Related Posts

External style sheets have many powerful that make them ubiquitous in professional Web sites: It keeps your website design and content separate. It's much easier to reuse your CSS code if you have it in a separate file. Instead of typing the same CSS code on every web page you have, simply have many pages refer to a single CSS file with the "link" tag. You can make drastic changes to your web pages with just a few changes in a single CSS file. It allows a single style sheet to control the rendering of multiple documents. This results in a time-savings for the author, a savings of space for the web server, and less download time for the user. This method can be used in both HTML and XML.

In this article we are going to learn, how to use transition, text-shadow and border-radius in CSS3.

This article describe how to write common css code to change the look and feel of html elements.

You must have came across some .css issues related with the browser behavior. Some of the styles that works in IE doesn't work in FireFox. In that situation you need to write conditional code for both browsers.

In this article we are going to learn, how to use Opacity, Scale and box shadow and Zooming effects in CSS 3.

More ...
About Us | Contact Us | The Team | Advertise | Software Development | Write for us | Testimonials | Privacy Policy | Terms of Use | Link Exchange | Members | Go Top
General Notice: If you find plagiarised (copied) contents on this page, please let us know the original source along with your correct email id (to communicate) for further action.
Copyright © DotNetFunda.Com. All Rights Reserved. Copying or mimicking the site design and layout is prohibited. Logos, company names used here if any are only for reference purposes and they may be respective owner's right or trademarks. | 5/25/2013 12:41:53 AM