-4

After having read all dotted border questions possible, and not having found an answer, I write my question below.

How do i remove the dotted border around the div when i click on a link inside it?

This image shows the word "photography", which has a dotted border when clicked on.

The basics behind this is just a dropdown, that appears when that section is clicked on, which works absolutely fine, i just cannot stand that border, does my nut in.

Any ideas?

Edward Nunn
  • 113
  • 7

2 Answers2

1

That's the focus state. Try to add this:

a:focus {
  outline: none;
}

Or if that element isn't a real link, but for example just an li, make that

li:focus {
  outline: none;
}
Johannes
  • 64,305
  • 18
  • 73
  • 130
  • Yes, thankyou at last. I'm using WordPress with the Avada theme, and all you need to do is add this to the Custom CSS area. a:focus { outline: none !important; } – Edward Nunn Mar 01 '17 at 13:15
0

You can use below css property.

a, a:hover, a:active, a:focus {
    outline: 0;
}

Please read this article - https://css-tricks.com/removing-the-dotted-outline/ and http://www.outlinenone.com/ for more clarification

Ranjit Kumar
  • 273
  • 3
  • 16