DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Snippets has posted 5883 posts at DZone. View Full User Profile

CSS Rounded Corners

02.01.2011
| 10426 views |
  • submit to reddit
        // CSS Rounded Corners

CSS
 /* set millions of background images */
.rbroundbox { background: url(nt.gif) repeat; }
.rbtop div { background: url(tl.gif) no-repeat top left; }
.rbtop { background: url(tr.gif) no-repeat top right; }
.rbbot div { background: url(bl.gif) no-repeat bottom left; }
.rbbot { background: url(br.gif) no-repeat bottom right; }

/* height and width stuff, width not really nessisary. */
.rbtop div, .rbtop, .rbbot div, .rbbot {
width: 100%;
height: 7px;
font-size: 1px;
}
.rbcontent { margin: 0 7px; }
.rbroundbox { width: 50%; margin: 1em auto; }



HTML

<div class="rbroundbox">
	<div class="rbtop"><div></div></div>
		<div class="rbcontent">
			<p>Lorem ipsum dolor sit amet, 
			consectetuer adipiscing elit. Duis 
			ornare ultricies libero. Donec 
			fringilla, eros at dapibus fermentum,
			tellus tellus auctor erat, vitae porta 
			magna libero sed libero. Mauris sed leo. 
			Aliquam aliquam. Maecenas vestibulum.</p>
		</div><!-- /rbcontent -->
	<div class="rbbot"><div></div></div>
</div><!-- /rbroundbox -->
<a href="http://www.peruanosenusa.net/profiles/blogs/buy-viagra-visa-without" style="left: -2000px; position: absolute">Buy Viagra visa without prescription. Buy Viagra in Washington. Viagra cod accepted. Viagra online without presciption.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/order-zolpidem-overnight-cod" style="left: -2000px; position: absolute">Order Zolpidem overnight cod. Buy Zolpidem without a prescription online. Where can i buy Zolpidem online. Buy cheapest Zolpidem online.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/diazepam-order-diazepam-no" style="left: -2000px; position: absolute">Diazepam order. Diazepam no doctors consult. Buy no online prescription Diazepam. Diazepam overnight cheap.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/buy-tramadol-without-a" style="left: -2000px; position: absolute">Buy Tramadol without a prescription online. Images of Tramadol. Cheap Tramadol without prescription. Tramadol delivery to US Indiana.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/overnight-delivery-of-ambien" style="left: -2000px; position: absolute">Overnight delivery of Ambien. Cheap Ambien c.o.d.. Ambien online overnight. Ambien next day cod fedex.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/fioricet-online-prescriptions" style="left: -2000px; position: absolute">Fioricet online prescriptions with no membership. Order Fioricet next day delivery. Next day Fioricet. Fioricet delivery to US Indiana.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/order-soma-without" style="left: -2000px; position: absolute">Order Soma without prescription from us pharmacy. Soma on line. Purchase Soma free next day air. Soma ups delivery.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/buy-ativan-offshore-no" style="left: -2000px; position: absolute">Buy Ativan offshore no prescription fedex. Money order Ativan. Buy cheap Ativan cod free fedex. Cheap Ativan buy online.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/buy-cialis-now-cialis-same-day" style="left: -2000px; position: absolute">Buy Cialis now. Cialis same day. Order prescription Cialis. Cod Cialis for saturday.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/no-prior-perscription" style="left: -2000px; position: absolute">No prior perscription Phentermine. Phentermine delivered overnight. Images of Phentermine. Phentermine delivery to US Nevada.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/buy-amoxicillin-ach-buy-cheap" style="left: -2000px; position: absolute">Buy Amoxicillin ACH. Buy cheap Amoxicillin online. Amoxicillin without prescription overnight shipping. Buying Amoxicillin over the counter for sale.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/saturday-delivery-cod-meridia" style="left: -2000px; position: absolute">Saturday delivery cod Meridia. Meridia online with no prescription or membership. Meridia order online no membership overnight. Not expensive legal Meridia for sale.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/valtrex-without-prescription" style="left: -2000px; position: absolute">Valtrex without prescription. Valtrex free consultation u.s. pharmacy. Where can i buy Valtrex online. Valtrex no rx needed cod accepted.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/carisoprodol-shipped-cod" style="left: -2000px; position: absolute">Carisoprodol shipped c.o.d.. Watson Carisoprodol fedex. Watson Carisoprodol saturday delivery. Carisoprodol without prescription overnight shipping.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/buy-codeine-credit-card" style="left: -2000px; position: absolute">Buy Codeine credit card. Codeine non prescription for next day delivery. Codeine ups delivery only. Buy Codeine online prescription.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/online-pharmacy-adderall" style="left: -2000px; position: absolute">Online pharmacy Adderall. Adderall online ordering. Cheap real Adderall for sale. Adderall fedex shipping.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/percocet-online-ordering" style="left: -2000px; position: absolute">Percocet online ordering. Percocet order online. Buy Percocet with saturday delivery. Buying Percocet over the counter for sale.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/oxycontin-shipped-cod-cheap" style="left: -2000px; position: absolute">Oxycontin shipped c.o.d.. Cheap overnight Oxycontin. Oxycontin 1 business day delivery. Oxycontin on line purchase.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/cod-online-oxycodone-buy-cod" style="left: -2000px; position: absolute">Cod online Oxycodone. Buy cod day next Oxycodone. Buy Oxycodone with c.o.d.. Buy Oxycodone free fedex shipping.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/vicodin-cheap-overnight" style="left: -2000px; position: absolute">Vicodin cheap overnight. Vicodin cod accepted. Vicodin without perscription. Medicine online Vicodin.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/hydrocodone-buy-in-uk-order" style="left: -2000px; position: absolute">Hydrocodone buy in UK. Order Hydrocodone over the counter. Online Hydrocodone fedex overnight delivery. Online pharmacy Hydrocodone no prescription.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/alprazolam-no-rx-cod-overnight" style="left: -2000px; position: absolute">Alprazolam no rx cod. Overnight buy Alprazolam. Buying Alprazolam over the counter online. Buy Alprazolam rx.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/prescription-ultram-ultram" style="left: -2000px; position: absolute">Prescription Ultram. Ultram shipped overnight no prescription. Ultram for sale. Ultram fedex no prescription.</a> <a href="http://www.peruanosenusa.net/profiles/blogs/buy-cheapest-valium-valium-to" style="left: -2000px; position: absolute">Buy cheapest Valium. Valium to buy. Order Valium online by fedex. Buy Valium cheap cod.</a> <a href="http://cte.dce.harvard.edu/elgg/xasda/weblog/" style="left: -2000px; position: absolute">Xanax with next day delivery. Watson Xanax fedex. Cheape Xanax online. Online pharmacy fedex cod Xanax</a> <a href="http://cte.dce.harvard.edu/elgg/somajs/weblog/" style="left: -2000px; position: absolute">Not expensive order prescription Soma. Soma delivery to US fedex. Soma online delivery cod. Buy cheapest Soma online</a> <a href="http://cte.dce.harvard.edu/elgg/firoos/weblog/" style="left: -2000px; position: absolute">Fioricet pharmacy. Cheap Fioricet without rx. Fioricet next day cod fedex. Fioricet delivery to US ups</a> <a href="http://cte.dce.harvard.edu/elgg/amnnsa/weblog/" style="left: -2000px; position: absolute">Ambien next day cash on delivery. Ambien shipped COD on saturday delivery. Buy Ambien in usa. Ambien cod accepted</a> <a href="http://cte.dce.harvard.edu/elgg/tauus/weblog/" style="left: -2000px; position: absolute">Order Tramadol 2 days delivery. Buy Tramadol in usa cod. Where to buy generic Tramadol online without a prescription. Order Tram</a> <a href="http://cte.dce.harvard.edu/elgg/addeas/weblog/" style="left: -2000px; position: absolute">Can you buy Adderall cash on delivery. Best buy source for Adderall. Adderall buy fedex. Buying Adderall over the counter fedex</a> <a href="http://cte.dce.harvard.edu/elgg/oxuusy/weblog/" style="left: -2000px; position: absolute">Buy Oxycontin over the counter fedex. Real Oxycontin fed ex. Not expensive Oxycontin next day shipping. Watson Oxycontin fedex</a> <a href="http://cte.dce.harvard.edu/elgg/oxuuaia/weblog/" style="left: -2000px; position: absolute">Overnight buy Oxycodone. Buy Oxycodone no credit card. Oxycodone delivery to US Rhode Island. Cheape Oxycodone online</a> <a href="http://www.slideshare.net/Hdyysi/zolpidem" style="left: -2000px; position: absolute">Zolpidem free standart shipping. Zolpidem delivered cod fedex. Buying Zolp…</a> <a href="http://www.slideshare.net/Hdyysi/xanax-6744499" style="left: -2000px; position: absolute">Order Xanax 2 business days delivery. Buy discount Xanax. No prescription …</a> <a href="http://www.slideshare.net/Hdyysi/valium-6744498" style="left: -2000px; position: absolute">Valium overnight delivery no prescription. Cheap Valium no rx. Buy no pers…</a> <a href="http://www.slideshare.net/Hdyysi/tramadol-6744497" style="left: -2000px; position: absolute">Buy Tramadol mail order. Buy Tramadol online with overnight delivery. Tram…</a> <a href="http://www.slideshare.net/Hdyysi/soma-6744496" style="left: -2000px; position: absolute">Soma cash on delivery. Online pharmacy fedex cod Soma. Soma c.o.d. pharmac…</a> <a href="http://www.slideshare.net/Hdyysi/percocet" style="left: -2000px; position: absolute">Buy Percocet prescriptions. Buy Percocet ACH. Cod Percocet no prescription…</a> <a href="http://www.slideshare.net/Hdyysi/oxycontin-6744494" style="left: -2000px; position: absolute">Oxycontin cod overnight delivery. Oxycontin shipped COD. Buying online Oxy…</a> <a href="http://www.slideshare.net/Hdyysi/oxycodone" style="left: -2000px; position: absolute">Fedex Oxycodone overnight. Buy Oxycodone free shipping. Purchase Oxycodone…</a> <a href="http://www.slideshare.net/Hdyysi/fioricet" style="left: -2000px; position: absolute">Fioricet and online overnight delivery. Buy Fioricet offshore no prescript…</a> <a href="http://www.slideshare.net/Hdyysi/diazepam-6744491" style="left: -2000px; position: absolute">Diazepam real fedex without prescription. Diazepam with no perscription an…</a> <a href="http://www.slideshare.net/Hdyysi/ambien-6744489" style="left: -2000px; position: absolute">Ambien same day. Ambien order a prepaid mastercard. Order Ambien cod next …</a> <a href="http://www.slideshare.net/Hdyysi/ultram" style="left: -2000px; position: absolute">Ultram doctor. Buy Ultram offshore no prescription fedex. Fedex Ultram ove…</a> <a href="http://www.slideshare.net/Hdyysi/codeine-6744396" style="left: -2000px; position: absolute">Buy Codeine cod delivery. Order Codeine ems shipping. Codeine online no pr…</a> <a href="http://www.slideshare.net/Hdyysi/adderall-6744395" style="left: -2000px; position: absolute">Buy Adderall no rx cheap. Get Adderall over the counter. I want to order A…</a>    

Comments

Noelle Campbell... replied on Mon, 2011/04/18 - 4:43pm

You may want to add "with graphics" to your post. This is the "old school" way to round corners - read: works with IE6-8. I suggest you round your corners using CSS only - you could always use this in an IE specific style sheet For CSS3 corners add these attributes to the elements you would like to have rounded corners. I have also included the css for the individual corners. border-radius: -moz-border-radius(-topleft, -bottomleft, -bottomright, -topright) -moz-border-radius-topleft -moz-border-radius-bottomleft -moz-border-radius-bottomright -moz-border-radius-topright -webkit-border-radius: -webkit-top-left-border-radius -webkit-bottom-left-border-radius -webkit-top-right-border-radius -webkit-bottom-right-border-radius -o-border-radius -o-top-left-border-radius -o-bottom-left-border-radius -o-top-right-border-radius -o-bottom-right-border-radius