jqTransform form表單美化插件使用方法
用法
1- 添加腳本包含在標(biāo)題部分的網(wǎng)頁(yè)
//required
<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript" src="js/jquery.jqtransform.min.js"></script>
2- 寫(xiě)你的 form
<form class="jqtransform">
<div class="rowElem">
<label for="name">Name: </label>
<input type="text" name="name" />
</div>
<div class="rowElem">
<input type="submit" value="send" />
<div>
</form>
3- 最后使用插件
After it, select the forms and call the jqTransform plugin. See some examples:
<script type="text/javascript">
$(function() {
//find all form with class jqtransform and apply the plugin
$("form.jqtransform").jqTransform();
});
</script>
兼容性:ie 6+, safari 2+, firefox 2+
附:select如有js聯(lián)動(dòng)效果,則不能美化。需要原有的select,如以下方法:
<script language="javascript">
$(function(){
$('.rowElem').jqTransform({imgPath:'jqtransformplugin/img/'});
});
</script>
<form action="" class="jqtransformdone" method="POST">
<div class="rowElem">
<label>標(biāo)題</label>
<input type="text" name="inputtext"/>
</div>
<div class="NOrowElem">
<label>地區(qū)</label>
<select name="select1">
<option selected="selected" value="0">省</option>
<option value="1523">北京</option>
<option value="1524">陜西省</option>
</select>
<select name="select2" >
<option selected="selected" value="">市</option>
<option value="1525">北京市</option>
<option value="1526">西安市</option>
</select>
</div>
</form>
相關(guān)文章
jQuery實(shí)現(xiàn)模仿微博下拉滾動(dòng)條加載數(shù)據(jù)效果
這篇文章主要介紹了jQuery實(shí)現(xiàn)模仿微博下拉滾動(dòng)條加載數(shù)據(jù)效果,涉及jQuery響應(yīng)下拉滾動(dòng)事件動(dòng)態(tài)操作頁(yè)面元素的技巧,需要的朋友可以參考下2015-12-12jQuery 連續(xù)列表實(shí)現(xiàn)代碼
你有沒(méi)有手工的編寫(xiě)過(guò)一些重復(fù)的代碼?你也覺(jué)得它們是如此的無(wú)聊吧。好了,這里有更好的解決辦法。2009-12-12jquery cookie實(shí)現(xiàn)的簡(jiǎn)單換膚功能適合小網(wǎng)站
使用jquery cookie做了一個(gè)簡(jiǎn)單的換膚功能適合小網(wǎng)站并且代碼低級(jí),具體實(shí)現(xiàn)過(guò)程如下,感興趣的朋友可以了解下2013-08-08Jquery創(chuàng)建層顯示標(biāo)題和內(nèi)容且隨鼠標(biāo)移動(dòng)而移動(dòng)
本文為大家介紹下使用Jquery創(chuàng)建一個(gè)層顯示標(biāo)題的內(nèi)容且隨鼠標(biāo)移動(dòng),具體的實(shí)現(xiàn)如下2014-01-01jQuery操作Dom元素與遍歷以及JS遍歷詳細(xì)講解
這篇文章主要介紹了jQuery操作Dom元素、jQuery遍歷、JavaScript遍歷,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)吧2023-01-01運(yùn)用jquery實(shí)現(xiàn)table單雙行不同顯示并能單行選中
(該方法是對(duì)《運(yùn)用jquery實(shí)現(xiàn)(table)單雙行不同顯示并能多行選中》的改進(jìn),適合于單行選擇)2009-07-07有關(guān)jQuery中parent()和siblings()的小問(wèn)題
本文通過(guò)一個(gè)實(shí)例給大家介紹有關(guān)parent()和siblings()問(wèn)題原因及解決方案,非常不錯(cuò)具有參考借鑒價(jià)值,感興趣的朋友一起看看吧2016-06-06jQuery入門(mén)介紹之基礎(chǔ)知識(shí)
本文主要給大家介紹了些jQuery的基礎(chǔ)知識(shí),算是一個(gè)入門(mén)的小知識(shí)庫(kù),包含jQuery簡(jiǎn)介、對(duì)象轉(zhuǎn)換、以及基本選擇器和層次選擇器等知識(shí)點(diǎn)。2015-01-01