Jquery 从选项卡内的链接附加到选项卡
考虑到jqGrid[]作者的示例格式,我如何在选项卡[#RightPane]中包含一个链接以附加到选项卡顶部?还有,让新选项卡显示AJAX内容吗?这应该让您开始:Jquery 从选项卡内的链接附加到选项卡,jquery,Jquery,考虑到jqGrid[]作者的示例格式,我如何在选项卡[#RightPane]中包含一个链接以附加到选项卡顶部?还有,让新选项卡显示AJAX内容吗?这应该让您开始: <script type="text/javascript"> $(function() { //this sets up the tabs $("#theTabs").tabs(); //this attaches the new tab functionallity
<script type="text/javascript">
$(function() {
//this sets up the tabs
$("#theTabs").tabs();
//this attaches the new tab functionallity to the link
$("#AddTabLink").click(function() {
$("#theTabs").tabs("add", "the url you want to load ajaxly", "The New Tab title");
}
);
});
</script>
and this is the link that will have the addtab functionality applied to it. this could go on an existing tab, or somewhere else on the page.
<a href="#" id="AddTabLink">Click Here</a>
$(函数(){
//这将设置选项卡
$(“#theTabs”).tabs();
//这会将新选项卡功能附加到链接
$(“#添加链接”)。单击(函数(){
$(“#theTabs”).tabs(“添加”、“要加载的url”、“新选项卡标题”);
}
);
});
这是一个将应用addtab功能的链接。这可以放在现有的选项卡上,也可以放在页面的其他地方。