Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

input focus outer glow

Tags:

html

jquery

css

is it possible to simulate the outer glow that safari and other browsers add to an input field? And avoiding jquery if possible?

This article explains how to remove it: http://www.altrugon.com/css/remove-safaris-input-focus-outer-glowquitar-el-border-azul-de-los-inputs-en-safari/

Thanks

like image 632
user441365 Avatar asked Nov 30 '22 04:11

user441365


1 Answers

Check out the DEMO

Here box-shadow is used in combination with :focus psudo selector.

CSS:

input:focus,textarea:focus,select:focus{
  border:1px solid #fafafa;
  -webkit-box-shadow:0 0 6px #007eff;
  -moz-box-shadow:0 0 5px #007eff;
  box-shadow:0 0 5px #007eff;
  outline: none;
}
like image 79
Sarfraz Avatar answered Dec 09 '22 19:12

Sarfraz