網頁設計~愛上JQUERY這本書我已經買了
真的覺得很是受用
目前看到某一個章節~jQuery的事件select範例功能
剛好發現只有FF跟Opera無法使用
我將程式碼PO出來看看
雖然這功能應該很少運用啦^^|||
test82.html
<script type="text/javascript" src="請換成jquery.js"></script>
<script type="text/javascript" src="myfirst82.js"></script>
<style>
.myselect
{
color: white;
background-color: red;
font: normal 90% "Arial"
}
</style>
<body>
name:<input type=text size=20>
</body>
myfirst82.js
$(document).ready(function(){
$(':input').select(function(){
$(this).addClass('myselect');
});
$(document).click(function(){
$(':input').removeClass('myselect');
});
});
[ 本帖最後由 bau720123 於 2009-5-11 17:51 編輯 ] |