Posted by : my solutions Thursday, December 20, 2012


These is very basic example to create a tab controller using jquery and accomplished one simple technique 'which is switching tab by using button" - it will help for u r real time environment
source code at aspx side [or] HTML page
---------------------------------------------------
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="utf-8" />
    <title>jQuery UI Tabs - Default functionality</title>
    <link rel="stylesheet" href="http://code.jquery.com/ui/1.9.2/themes/base/jquery-ui.css" />
    <script src="http://code.jquery.com/jquery-1.8.3.js"></script>
    <script src="http://code.jquery.com/ui/1.9.2/jquery-ui.js"></script>
    <link rel="stylesheet" href="/resources/demos/style.css" />
    <script>
        $(function () {
            $("#tabs").tabs();
        });
    </script>
    <script type="text/javascript">
        $(document).ready(function () {
            $(nxt).click(function () {
                $("#tabs").tabs("select", "#tabs-2");
            });
        });
    </script>
</head>
<body>

<div id="tabs">
    <ul>
        <li><a href="#tabs-1">pallamalli</a></li>
        <li><a href="#tabs-2">maruthi</a></li>
        <li><a href="#tabs-3">Processweaver software solutions </a></li>
    </ul>
    <div id="tabs-1">
        <p>First tab</p>
    </div>
    <div id="tabs-2">
        <p>Second tab.</p>
    </div>
    <div id="tabs-3">
        <p>Third tab</p>
    </div>
</div>
 <input type="button" value="click-next" id="nxt" />

</body>

-------------------------------
Note :- Move the third tab means [or] what ever the tab u want to move means  $("#tabs").tabs("select", "#tabs-2");

Give your tab id at "#tabs-2" place

Output view :-


Leave a Reply

Subscribe to Posts | Subscribe to Comments

- Copyright © complete .net tutorials - Skyblue - Powered by Blogger - Designed by Johanes Djogan -