[英]CSS rollover effects with RichFaces a4j:commandButton
我還沒有看到有用的權威性Web資源,該資源說明了如何在RichFaces JSF內容中的a4j:commandButton
元素上可靠地啟用翻轉效果。
我發現大量的CSS資源重新按鈕,但是當他們開始談論html時,我開始懷疑在最新的Web技術中,等效的是什么。
基本上,我希望我的按鈕在懸停然后在單擊時看起來有所不同。 我想使用圖片,但是客戶端js不在此范圍之內。
米
在下面的示例中,對a4j:commandButton
使用以下屬性(請查看完整列表 (v3.3.1.GA)):
<a4j:commandButton value="Submit" styleClass="ctlBtn"
id="myCtlBtn" type="submit" style="margin-bottom: 5px;"
reRender="allMyOtherplaces"
onmouseover="this.className='ctlBtn btnHover'"
onmousedown="this.className='ctlBtn btnDown'"
onmouseup="this.className='ctlBtn'"
onmouseout="this.className='ctlBtn'"
onclick="this.className='ctlBtn btnDown'"
oncomplete="this.className='ctlBtn'" />
並在包含的.css文件中創建類ctlBtn
, btnHover
和btnDown
。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.