define two classes in your style sheet
Code:
.oldclass {
background-color:#ccc;
background-image: url(pic.gif);
color:#333;
}
.newclass {
background-color:#333;
background-image: url(pic_over.gif);
color:#ccc;
}
now any input tag that contains the following code
Code:
<input class="oldclass" type="submit" name="Submit" value="Submit" onmouseover="this.className='newclass';" onmouseout="this.className='oldclass';">
will have a mouse over effect. The pic.gif is normal state and pic_over.gif is hover state images resp.