Below is the link of my code which is working fine in Fiddle
Fiddle Link : http://jsfiddle.net/JdU8N/
But the same code doesn't work in my local . I have properly loaded the jQuery files and have initiated the tabs in $(document).ready(function(){}); . With firebug , i don't get any error too 
This is my code :
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>Untitled Document</title>
        <script type="text/javascript" src="http://code.jquery.com/jquery-1.9.1.js"></script>
        <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.9.2/jquery-ui.js"></script>
        <script>
            $(document).ready(function() {
                $('.tabs').tabs();
                $('.subtabs').tabs({
                    activate: function(event, ui) {
                        //get relative li index
                        var secondTabSelected = $(ui.newTab).index();
                        console.log(secondTabSelected);
                    }
                });
            });
        </script>
    </head>
    <body>
        <div class="tabs">
            <ul>
                <li><a href="#tabs-1">Tab 1</a></li>
                <li><a href="#tabs-2">Tab 2</a></li>
            </ul>
            <div id="tabs-1">
                <div class="subtabs">
                    <ul>
                        <li><a href="#tabs-1a">Tab 1-A</a></li>
                        <li><a href="#tabs-1b">Tab 1-B</a></li>
                    </ul>
                    <div id="tabs-1a">
                        <p>Tab 1A</p>
                    </div>
                    <div id="tabs-1b">
                        <p>Tab 1B</p>
                    </div>
                </div>
            </div>
            <div id="tabs-2">
                <div class="subtabs">
                    <ul>
                        <li><a href="#tabs-2a">Tab 2-A</a></li>
                        <li><a href="#tabs-2b">Tab 2-B</a></li>
                    </ul>
                    <div id="tabs-2a">
                        <p>Tab 2A</p>
                    </div>
                    <div id="tabs-2b">
                        <p>Tab 2B</p>
                    </div>
                </div>
            </div>
        </div>
    </body>
</html>
Any help would be appreciated ...
 
     
     
     
    