Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 720087
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T05:43:06+00:00 2026-05-14T05:43:06+00:00

I am using CSS rounded corners for firefox and I have the following problem

  • 0

I am using CSS rounded corners for firefox and I have the following problem with content boundaries:

Code

<html>
<head>
   <style>
      #outter {
            width: 200px;
            margin: auto;
            text-align: center;
            border: 1px solid #333;
            -moz-border-radius: 15px;
        }
        #inner {
            background: red;
            opacity: 0.5;
        }
    </style>
</head>
<body>
<div id="outter">
    <div id="inner">text</div>
</div>
</body>
</html>

Effect

alt text http://img256.imageshack.us/img256/2108/testew.png

I can avoid this problem by defining -moz-border-radius for each outter’s child. There is any other way I am missing?

Edit

A harder test with multiple inner divs with different background-color for each one:

<div id="outter">
    <div id="inner1" style="background: blue">text</div>
    <div id="inner2" style="background: gray">text</div>
    ...
    <div id="innerN" style="background: yellow">text</div>
</div>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T05:43:07+00:00Added an answer on May 14, 2026 at 5:43 am

    You can also do this:

      #outter {
            width: 200px;
            margin: auto;
            text-align: center;
            border: 1px solid #333;
            -moz-border-radius: 15px;
            background: red;
        }
        #inner {
            opacity: 0.5;
        }
    

    Moving the background to the rounded parent will render correctly, see here for an example: http://jsfiddle.net/mE8En/ (only works in firefox!) add the webkit border radius if you want to support other webkit based browsers as well, like this:

    -moz-border-radius: 15px; 
    -webkit-border-radius: 15px;
    

    Update for edit: To handle the inner divs in firefox subtract a pixel on the inner div to compensate for the border, resulting in this:

    #outter {
        width: 200px;
        margin: auto;
        text-align: center;
        border: 1px solid #333;
        -moz-border-radius: 15px;
        -webkit-border-radius: 15px;
        background: red;
    }
    #outter > div:first-child {
        -moz-border-radius-topleft: 14px;
        -moz-border-radius-topright: 14px;
         -webkit-border-top-left-radius: 14px;
         -webkit-border-top-right-radius: 14px;
    }
    #outter > div:last-child {
        -moz-border-radius-bottomleft: 14px;
        -moz-border-radius-bottomright: 14px;
         -webkit-border-bottom-left-radius: 14px;
         -webkit-border-bottom-right-radius: 14px;
    }
    #inner {
        opacity: 0.5;
    }
    ​
    

    Note: the radii aren’t perfect on the inner divs in webkit, adjust as desired…this is because the rendering isn’t pixel perfect between browsers.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 524k
  • Answers 524k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer I use this technique on most of my apps. Basicaly… May 16, 2026 at 10:01 pm
  • Editorial Team
    Editorial Team added an answer This works for me using Jersey. Add a variable; @Context… May 16, 2026 at 10:01 pm
  • Editorial Team
    Editorial Team added an answer mario nailed it (copied from the comments) Access modifiers make… May 16, 2026 at 10:01 pm

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

How can I create rounded corners using CSS?
I'm currently using a combination of CSS and Div tags to achieve rounded corners
I have an HTML 5 web page using CSS 3 and have tested it
I found an example here of using rounded corners using a single image. I've
I am using the following css #helper{ position:absolute; bottom:0; width:100%; } #key{ width:950px; margin:0
How to create a rounded corner background box using CSS?
I expect following code to put my span to the top-left corner of the
I have the following markup for buttons (can be changed, but I really don't
Using the code below, both Chrome and Opera (latest versions supporting border-radius) on Mac
Having a bit of an issue please see the following code: window.onload = function

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.