Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Remove 3D push effect on a button

Tags:

html

css

I'm trying to remove all effects on a HTML Button element. The HTML:

<div id="go"> <button onclick="load.update(true,cards.id);" type="submit"></button> </div> 

The CSS:

#header #go button{     display:block;     border:0 none;     cursor:pointer;     outline:none;     vertical-align:top;     width:18px;     height:33px;     background:url('../images/cards/go.png'); //Just an image to replace it all. } 

In Chrome and Firefox this works fine, but in IE (8 at least) the "push" effect of the button is still there when the button is clicked (EG the offset) Is there any Tricks i can use to remove this effect? Thanks in advance! Diesal.

like image 202
Diesal11 Avatar asked Mar 29 '11 01:03

Diesal11


1 Answers

you need to add background styles to :hover :active :focus as well.

#header #go button:hover { border: none; outline:none; padding: 5px; background:url('../images/cards/go.png'); }  #header #go button:active { border: none; outline:none; padding: 5px; background:url('../images/cards/go.png'); }  #header #go button:focus { border: none; outline:none; padding: 5px; background:url('../images/cards/go.png'); } 
like image 102
Mark Avatar answered Oct 05 '22 05:10

Mark