我正在創建一個使用標準圖像作爲提交按鈕的HTML聯繫表單。如何創建提交按鈕鼠標懸停?
下面是HTML:
<form action="#">
<fieldset>
<input type="text" name="name" value="FULL NAME" onfocus="if (this.value=='FULL NAME') this.value='';"/>
<input type="text" name="" value="PHONE NUMBER" onfocus="if (this.value=='PHONE NUMBER') this.value='';"/>
<input type="text" name="" value="EMAIL" onfocus="if (this.value=='EMAIL') this.value='';"/>
<input type="text" name="" value="MOVE DATE" onfocus="if (this.value=='MOVE DATE') this.value='';"/>
<input type="text" name="" value="ORIGINATING ADDRESS" onfocus="if (this.value=='ORIGINATING ADDRESS') this.value='';"/>
<input type="text" name="" value="DESTINATION ADDRESS" onfocus="if (this.value=='DESTINATION ADDRESS') this.value='';"/>
<select name="type">
<option value="Private">Private</option>
<option value="Commercial">Commercial</option>
</select>
<input id="quoteSubmit" type="image" src="_images/btn_submit.png" alt="" />
</fieldset>
</form>
靜態提交按鈕圖像是好的,但我想改變它的鼠標懸停到btn_submit-over.png。
我熟悉使用css精靈的mouseovers,但它們不適用於提交按鈕。我希望得到一些幫助。
謝謝!
比腳本好得多。酷站點,jsbin btw – mplungjan 2010-07-05 14:24:45
http://stackoverflow.com/questions/195632/how-to-change-input-button-image-using-css – mplungjan 2010-07-05 14:26:24