Search code examples
cssinputborder

Border color on default input style


here's a tricky question...

I have default styled input fields (no css added, just width/height/padding), but now I want to give it a red border (error style). How can I do this? Just setting border will delete the default style of the input, setting only border-color will look weird, setting an outline will work in some cases (and doesn't look so good in Firefox).

Any tips?

EDIT: Come on guys read the question before answering. I want the browser default look of the input, I just want to give it a red border.


Solution

  • I would have thought this would have been answered already - but surely what you want is this: box-shadow: 0 0 3px #CC0000;

    Example: http://jsfiddle.net/vmzLW/