Вопрос

I've found the following question and related answer to change the outerglow of bootstrap input types:

How can I change the border/outline color for input and textarea elements in Twitter Bootstrap?

However, it doesn't seem to work for textareas, even though textarea:focus is targeted with the CSS. All other input types work correctly. Does anyone know why this occurs?

Это было полезно?

Решение

Check that the element which is not being styled is definitely a <textarea>.

If it is, perhaps a later style overrides the one you've added - test this by putting !important at the end of your new styles e.g:

textarea:focus, input:focus, input[type]:focus, .uneditable-input:focus {   
    border-color: rgba(229, 103, 23, 0.8)!important;
    box-shadow: 0 1px 1px rgba(229, 103, 23, 0.075) inset, 0 0 8px rgba(229, 103, 23, 0.6)!important;
    outline: 0 none!important;
}

If it is being overriden it would be better practice to set a new class on your textarea and apply your desired styles to that class, later in the css than the overriding style.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top