nsdlfefinedieicbe nsdlfefinedieicbe - 6 months ago 10
HTML Question

background color is changing once we click cursor inside textfield

once we click cursor inside textfield , background color is changing.

Before :

enter image description here

once we click cursor inside textfield :

enter image description here

but i want to keep the same color after click cursor inside textfield.

css

input.input-text, select, textarea {
font: /*BEGIN:general_font*/12px/1.35 Arial, Helvetica, sans-serif/*END:general_font*/;
padding: 2px 8px !important;
border: 1px solid /*BEGIN:body_line1*/#dcdcdc/*END:body_line1*/;
color: /*BEGIN:body_text_color3*/#a0a0a0/*END:body_text_color3*/;
height: 29px;
line-height: 29px;
width: 80%;
}

input, select, textarea, button {
vertical-align: middle;

}


phtml

<input type="text" class="input-text" name="s" placeholder='<?php echo $helper->__('Search by product name') ?>'
value="<?php echo $this->getRequest()->getParam('s')?>"/>

Answer

Remove this media query in your code and it works :)

@media (min-width: 0)
:focus {
     background: none; 
}

Screenshot of the issue