10

I have a radius div with 5px dashed border, but border not show properly in Firefox. It show well in IE and chrome.

Demo

 div{
        height:100px;
        width: 100px;
        background-color: #ccc;
        border-radius: 50%;
        border:5px dashed #333;
    }
Mukul Kant
  • 7,074
  • 5
  • 38
  • 53

2 Answers2

12

Your border is working on firefox see DEMO you can check it with removing radius. FireFox having bug when you tried circle with dashed border.

This is a known bug. Your options are:

  • If this is just for the sake of a circle, draw it with <canvas>, e.g. as demonstrated here
  • Use SVG (possibly inline), which supports various ways to stroke paths
  • Just make a Image PNG
Community
  • 1
  • 1
Manwal
  • 23,450
  • 12
  • 63
  • 93
3

It's a bug, Here are all the other outstanding border-radius defects in Firefox. https://bugzilla.mozilla.org/show_bug.cgi?id=431176

old thread

Why does border: 5px dashed not come out as dashed in Firefox?

you can achieve it using image

http://www.guyroutledge.co.uk/blog/better-dotted-borders-with-border-image/

Community
  • 1
  • 1
Manjunath Siddappa
  • 2,126
  • 2
  • 21
  • 40