DotNetNuke has a Jquery DNNTabs Plugin. You can just copy and paste the following code in your .ascx control.
<script type="text/javascript">
jQuery(function ($) {
$('#tabs').dnnTabs();
});
</script>
<div id="tabs" class="dnnForm dnnModuleSettings dnnClear">
<ul class="dnnAdminTabNav dnnClear">
<li><a href="#tab1">Tab1</a></li>
<li><a href="#tab2">Tab2</a></li>
</ul>
<div id="tab1">
Some content...
</div>
<div id="tab2">
Success
</div>
</div>
<script type="text/javascript">
jQuery(function ($) {
$('#tabs').dnnTabs();
});
</script>
<div id="tabs" class="dnnForm dnnModuleSettings dnnClear">
<ul class="dnnAdminTabNav dnnClear">
<li><a href="#tab1">Tab1</a></li>
<li><a href="#tab2">Tab2</a></li>
</ul>
<div id="tab1">
Some content...
</div>
<div id="tab2">
Success
</div>
</div>
Thanks for sharing this.
ReplyDeleteIs it also possible to choose the tab you want to show?
Something like:
$('#tabs').dnnTabs("show",2);
?