清除使用jQuery的选项卡里面的所有控件 [英] clear all controls inside tab using jquery
本文介绍了清除使用jQuery的选项卡里面的所有控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个包含5个选项卡的TabContainer的。我想要清除里面的每一个TAB1的使用Jquery什么是实现这一目标的最佳途径控件的所有数据?
I have a tabcontainer which contains 5 tabs. I want to clear all data inside each of the controls of tab1 using Jquery what is the best way to achieve this?
推荐答案
下面将从给定的选择器匹配的元素删除所有内容:
The following will remove all content from elements matched with the given selector:
$(<在这里选择>中)HTML();
修改
要删除输入元素中的数据:
To remove data inside input elements:
$(<在这里选择>输入)。VAL();
如果 TABL
是一个类,然后使用 .tabl
作为选择。如果它是一个id,使用 #tabl
。
If tabl
is a class, then use .tabl
as the selector. If it is an id, use #tabl
.
这篇关于清除使用jQuery的选项卡里面的所有控件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文