function toggleopen(which, offset) {
    if (document.getElementById('res' + which).className == "resources") {
        document.getElementById('res' + which).className = "resourcesopen";
        document.getElementById('divresources').style.height = document.getElementById('divresources').offsetHeight - 10 + offset +'px';
//        alert(document.getElementById('divresources').style.height + ' ' + document.getElementById('divresources').offsetHeight + ' ' + offset);
    } else {
        document.getElementById('res' + which).className = "resources";
        document.getElementById('divresources').style.height = document.getElementById('divresources').offsetHeight - 10 - offset + 'px';
//        alert(document.getElementById('divresources').style.height + ' ' + document.getElementById('divresources').offsetHeight + ' ' + offset);        
    }
    return true;
}

function topmenu() {
    document.write('<div class="subnavdiv"><p class="secondnav">');
    document.write('<a href="index.html" class="secondnavlink">HOME</a>&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="tour.html" class="secondnavlink">TAKE A TOUR</a>');
    document.write('&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="advantages.html" class="secondnavlink">TATA COMMUNICATIONS ADVANTAGES</a>');
    document.write('&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="contact.asp" class="secondnavlink">CONTACT US</a>');
    document.write('&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="locations.html" class="secondnavlink">LOCATIONS</a>');
    document.write('&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="mnews.asp" class="secondnavlink">MULTIMEDIA</a>');
//    document.write('<a href="https://tata.vnocservice.com/Login.aspx?ReturnUrl=%2fDefault.aspx" target="_blank" class="secondnavlink">RESERVE A PUBLIC ROOM</a>');
    document.write('</p>');
    document.write('</div>');
}

function footermenu() {
    document.write('<div class="footerbox">');
    document.write('<p class="footer">');
    document.write('<a href="about.html" class="footerlink">About Tata Communications</a>');
    document.write('&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="mnews.asp" class="footerlink">Multimedia</a>');
    document.write('&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="contact.asp" class="footerlink">Contact Us</a>');
    document.write('&nbsp;&nbsp;|&nbsp;&nbsp;');
    document.write('<a href="partners.html" class="footerlink">About the Partners</a>');
    document.write('</p>');
    document.write('</div>');
    var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
    document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
    try {
    var pageTracker = _gat._getTracker("UA-3642797-4");
    pageTracker._trackPageview();
    } catch(err) {}
}

function sidebar(arg) {
    document.write('<div class="sidebar" id="sidetest">');
    document.write('<div class="sidebarbox1"> <img src="_images/interior/private_rooms.gif" style="padding-bottom:9px;"/>');
    document.write('<p class="sidebartext">To set up your own telepresence rooms, <a href="contact.asp">contact a Tata Communications advisor</a>.</p>');
    document.write('</div>');
    document.write('<div class="sidebarbox2"> <img src="_images/interior/reserve.gif" alt="Reserve a Room" /> <img src="_images/interior/map.jpg" alt="Map" style="padding-bottom:5px;" />');
    document.write('<div align="center"> <a href="https://tata.vnocservice.com/Login.aspx?ReturnUrl=/Default.aspx" target="_blank"> <img src="_images/interior/btn_reserve.png" alt="Reserve Now" width="108" height="35" border="0px" /></a> <a href="locations.html"> <img src="_images/interior/btn_locations.png" alt="Locations" width="108" height="35" border="0px" /> </a> </div>');
    document.write('</div>');

    document.write('<div class="sidebarbox0" id="divresources"><img src="_images/home/resources.gif" alt="Resources" width="95" height="14" />');
    document.write('<ul class="resources"><li class="resources" id="resmap" style="cursor:pointer;" onclick="toggleopen(\'map\',27);"><a href="Javascript:void(0);" class="resgroup">Map</a><br /><a href="_pdfs/locations_map.pdf" target="_new">Letter size pdf<br /></a><a href="_pdfs/locations_map_A4.pdf" target="_new">A4 size pdf</a></li>');
    document.write('<li class="resources" id="resfs" style="cursor:pointer;" onclick="toggleopen(\'fs\',27);"><a href="Javascript:void(0);" class="resgroup">Fact Sheets</a><br /><a href="_pdfs/tata_tp_private_room_fact_sheet.pdf" target="_new">Private Room<br /></a><a href="_pdfs/tata_tp_public_room_fact_sheet.pdf" target="_new">Public Room</a></li>');
//    document.write('<li class="resources" id="respg" style="cursor:pointer;" onclick="toggleopen(\'pg\',42);"><a href="Javascript:void(0);" class="resgroup">Product Guides</a><br /><a href="resources/pg_valueprop.pdf">Value Proposition<br /></a><a href="resources/pg_prodpres.pdf">Product Presentation<br /></a><a href="resources/pg_servdesc.pdf">Service Description</a></li>');
    document.write('<li class="resources" id="resug" style="cursor:pointer;" onclick="toggleopen(\'ug\',27);"><a href="Javascript:void(0);" class="resgroup">User Guides</a><br /><a href="#" style="color:#808080;">Private Room<br /></a><a href="_pdfs/tata_tp_public_room_user_guide.pdf" target="_new">Public Room</a></li>');
    document.write('<li class="resources" id="resp" style="cursor:pointer;" onclick="toggleopen(\'p\',14);"><a href="Javascript:void(0);" class="resgroup">Pricing</a><br /><a href="Javascript: void(0)" onclick="window.open(\'tariffs-room.htm\',\'tariff\',\'width=500,height=380\')">Public Room</a></li></ul>');
    document.write('</div>');

    // Fix height for browsers other than IE
    var browser = navigator.appName
    if (browser.indexOf("Microsoft") == -1) { document.getElementById('divresources').style.height = document.getElementById('divresources').offsetHeight + 10 + 'px'; }
    if (arg != "1") {
        document.write('<div class="sidebarbox3">');
        showImage();
        document.write('<div style="text-align:right"><p><a href="http://www.carbonify.com/carbon-calculator.htm" target="_blank" class="sidebarbox3link">CALCULATOR &gt;</a></p></div>');
        document.write('</div>');
    } else {
    document.write('<div class="sidebarboxbanners"><br /><a href="usersclub.asp"><img src="_images/home/tp_uc_banner.gif" border="0" style="margin-top:5px;" /></a></div>');
// ** Banner removed 6/25    
//    document.write('<div class="sidebarboxanim"><a href="edm.html" target="_blank"><img src="_images/home/banner-travelworkmore.gif" border="0" /></a></div>');

//    document.write('<a href="" target="_blank"><img src="_images/home/banner-travelworkmore.gif" border="0" width="255" hspace="0" style="padding:0px 0px 0px 0px;" alt="Spend less on Travel, Gain time for Work, Do More></a>');
//document.write('</div></div>');
    }
    document.write('</div>');
}