What is this weird white border that appears around the HTML input button?

Here is a screenshot.

And my CSS markup:

.submitbutton { background: url("/Content/SiteImages/button.png") no-repeat scroll 0 0 transparent; color: white; cursor: pointer; height: 26px; width: 76px; margin-left: 8px; margin-top: 12px; } 

In addition, I need the background image to stretch to fit the size of the button. It is currently being displayed in full size (I think). Any tips for this new HTML web developer?

+4
source share
2 answers

HTML buttons always have a border, just setting border:0; should fix it.

+7
source

Try to specify

 background: 0; outline: 0; 

On him.

Note. This should only be used for testing purposes, by turning off the loop so that people who moved with their keyboards do not receive feedback when focusing on your button.

If this works, try using a finer outline.

0
source

All Articles