var siteTransform = new Array();
siteTransform['cc_corp_history_nwa'] = new Array();
siteTransform['cc_corp_history_nwa']['stage.siemens.com'] = 'stage.siemens.com/cc/corp/history_nwa';   //Server: stage
siteTransform['cc_corp_history_nwa']['backstage.siemens.com'] = 'backstage.siemens.com/cc/corp/history_nwa';   //Server: backstage
siteTransform['cc_corp_history_nwa']['www.siemens.com'] = 'www.siemens.com/history';   //Server: live

// This file is auto generated. Do not edit.
// See cms/apps/SiteExplorer for further information
var currentSite = window.location.host;

var sitetree = Class.create();
sitetree.prototype = {
    initialize: function()
    {
        SiteExplorer.getContent = function() {
            return '<ul>'
                       
                    +'<li class="collapsed">'
                    +'  <a class="collapsed" href="javascript:void(0);">History'
                    +'  </a>'
                    +'  <ul>'
                    +'      <li>'
                        
                    +'          <a class="page" rel="861" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/index.htm">Overview</a>'
                            
                    +'      </li>'
                            
                    +'<li>'
                    +'  <a class="page" rel="853" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1847_1865_beginnings_and_initial_expansion.htm">Company development 1847-1865'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="854" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1865_1890_triumph_of_heavy_current_engineering_and_internationalization.htm">Company development 1865-1890'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="855" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1890_1918_growth_trough_consolidation_and_partnerships.htm">Company development 1890-1918'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="856" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1918_1933_return_to_the_world_market_and_unity_within_the_house_of_siemens.htm">Company development 1918-1933'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="857" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1933_1945_the_national_socialist_economy_and_the_war_years.htm">Company development 1933-1945'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="858" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1945_1966_reconstruction_and_emergence_as_a_global_player.htm">Company development 1945-1966'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="859" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1966_1989_new_markets_and_areas_of_business.htm">Company development 1966-1989'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="860" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/history/1989_2008_deregulation_and_globalization.htm">Company development 1989-2008'
                    +'  </a>'
                    +'</li>'
                
                    +'  </ul>'
                    +'</li>'
                
                    +'<li class="collapsed">'
                    +'  <a class="collapsed" href="javascript:void(0);">Innovations'
                    +'  </a>'
                    +'  <ul>'
                    +'      <li>'
                        
                    +'          <a class="page" rel="869" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/index.htm">Overview</a>'
                            
                    +'      </li>'
                            
                    +'<li>'
                    +'  <a class="page" rel="870" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/information_and_communications.htm">Information &amp; Communications'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="871" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/power.htm">Power'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="872" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/transportation.htm">Transportation'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="873" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/healthcare.htm">Healthcare'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="879" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/industryautomation.htm">Industry &amp; Automation'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="877" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/lighting.htm">Lighting'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="878" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/innovations/household_appliances.htm">Household Appliances'
                    +'  </a>'
                    +'</li>'
                
                    +'  </ul>'
                    +'</li>'
                
                    +'<li class="collapsed">'
                    +'  <a class="collapsed" href="javascript:void(0);">Personalities'
                    +'  </a>'
                    +'  <ul>'
                    +'      <li>'
                        
                    +'          <a class="page" rel="862" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/personalities/index.htm">Overview</a>'
                            
                    +'      </li>'
                            
                    +'<li>'
                    +'  <a class="page" rel="863" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/personalities/founder_generation.htm">Founder generation'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="864" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/personalities/family.htm">Family'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="865" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/personalities/chairmen_of_the_managing_board_parent_companies.htm">Chairmen of the Managing Board, parent companies'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="866" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/personalities/chairmen_of_the_managing_board_siemens_ag.htm">Chairmen of the Managing Board, Siemens AG'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="867" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/personalities/scientists_and_engineers.htm">Scientists and engineers'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="868" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/personalities/creators_and_designers.htm">Creators and designers'
                    +'  </a>'
                    +'</li>'
                
                    +'  </ul>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="936" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/countries.htm">Countries'
                    +'  </a>'
                    +'</li>'
                
                    +'<li class="collapsed">'
                    +'  <a class="collapsed" href="javascript:void(0);">Affiliated Companies'
                    +'  </a>'
                    +'  <ul>'
                    +'      <li>'
                        
                    +'          <a class="page" rel="874" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/affiliated_companies/index.htm">Overview</a>'
                            
                    +'      </li>'
                            
                    +'<li>'
                    +'  <a class="page" rel="875" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/affiliated_companies/former_affiliates.htm">Former Affiliates'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="876" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/affiliated_companies/current-affiliates.htm">Current Affiliates'
                    +'  </a>'
                    +'</li>'
                
                    +'  </ul>'
                    +'</li>'
                
                    +'<li class="collapsed">'
                    +'  <a class="collapsed" href="javascript:void(0);">Siemens Corporate Archives'
                    +'  </a>'
                    +'  <ul>'
                    +'      <li>'
                        
                    +'          <a class="page" rel="987" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/siemens_corporate_archives.htm">Overview</a>'
                            
                    +'      </li>'
                            
                    +'<li>'
                    +'  <a class="page" rel="998" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/siemens_corporate_archives/profile.htm">Profile'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="1002" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/siemens_corporate_archives/services.htm">Services'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="996" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/siemens_corporate_archives/history_archives.htm">History of the Archives'
                    +'  </a>'
                    +'</li>'
                
                    +'<li class="collapsed">'
                    +'  <a class="collapsed" href="javascript:void(0);">Archives Network'
                    +'  </a>'
                    +'  <ul>'
                    +'      <li>'
                        
                    +'          <a class="page" rel="988" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/siemens_corporate_archives/archives_network.htm">Overview</a>'
                            
                    +'      </li>'
                            
                    +'<li>'
                    +'  <a class="page" rel="995" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/siemens_corporate_archives/archives_network/regional_archives.htm">Regional Archives'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="994" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/siemens_corporate_archives/archives_network/group_archives.htm">Group Archives'
                    +'  </a>'
                    +'</li>'
                
                    +'  </ul>'
                    +'</li>'
                
                    +'  </ul>'
                    +'</li>'
                
                    +'<li class="collapsed">'
                    +'  <a class="collapsed" href="javascript:void(0);">News Archive &amp; Downloads'
                    +'  </a>'
                    +'  <ul>'
                    +'      <li>'
                        
                    +'          <a class="page" rel="1018" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/news_archive_downloads.htm">Overview</a>'
                            
                    +'      </li>'
                            
                    +'<li>'
                    +'  <a class="page" rel="1019" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/news_archive_downloads/news_archive.htm">News Archive'
                    +'  </a>'
                    +'</li>'
                
                    +'<li>'
                    +'  <a class="page" rel="1020" href="'+window.location.protocol+'//'+siteTransform['cc_corp_history_nwa'][currentSite]+'/en/news_archive_downloads/downloads.htm">Downloads'
                    +'  </a>'
                    +'</li>'
                
                    +'  </ul>'
                    +'</li>'
                
                     +'</ul>';
        }
    }
}

SiteExplorer.expandSubtree = function(linkNode) {
    linkNode.addClassName("expanded");
    linkNode.up().removeClassName("collapsed");
    linkNode.up().addClassName("expanded");
    SiteExplorer.layer.afterOpen();
}

SiteExplorer.collapseSubtree = function(linkNode) {
    linkNode.removeClassName("expanded");
    linkNode.up().addClassName("collapsed");
    linkNode.up().removeClassName("expanded");
    SiteExplorer.layer.afterOpen();
}

SiteExplorer.followLink = function(linkNode) {
    if (linkNode.innerHTML != "Home") {
        //alert("clicked link: " + linkNode.innerHTML + "\nThe Site Explorer will be closed.");
        Layer.closeCurrent();
    }
}

SiteExplorer.openTree = function(page_key) {
    $$('#site-explorer-layer a[rel="'+page_key+'"]').each(function(a) {
        l = a.up();
        l.addClassName("active").update('<span class="active">'+a.innerHTML+'</span>');

        while (l.tagName != 'DIV')
        {
            l = l.up();
            if(l.tagName == 'LI')
            {
                l.removeClassName("collapsed");
                l.addClassName("expanded");
                l.firstDescendant().removeClassName("collapsed");
                l.firstDescendant().addClassName("expanded");
            }
        }

    });
}
/* 
 * explicitly overwrite SiteExplorerLayer.getContent from script.js to call 
 * SiteExplorer.openTree(siteExplorerActivePage);
 * avoids modifying script.js
*/


/* START: site explorer layer                                       */
var SiteExplorerLayer = Class.create();

SiteExplorerLayer.prototype = Object.extend(new Layer, {

    initialize: function(node, trigger) {
        this.initSuper(node, trigger);

        var closeButton = Helper.getCloseButton(this.node);

        closeButton.observe("click",
            function() {
                this.close();
            }.bindAsEventListener(this)
        );

        this.content     = null;
        this.contentNode = $(document.createElement("div"));
        this.node.appendChild(this.contentNode);
    },

    afterClose: function(newLayer) {
        if (!Layer.toggle) {
            HeaderAnimation.augment();
        }
    },

    afterOpen: function() {
        if (Info.browser.isIE) { // correct float bug in all IE versions
            Helper.getCloseButton(this.node).setStyle(
                {
                    position: "absolute",
                    left: (this.contentNode.getDimensions().width - 20) + "px"
                }
            );
        }
        HeaderAnimation.diminish();
    },

    beforeClose: function() {
        HeaderAnimation.unregisterLayer();
        return true;
    },

    beforeOpen: function() {
        this.getContent();
        HeaderAnimation.registerLayer(this);
        return true;
    },

    hide: function() {
        $("site-explorer").removeClassName("active");
    },

    show: function() {
        $("site-explorer").addClassName("active");
        this.trigger.addClassName("clicked"); // avoids hover effect (only for the first time)
        this.trigger.observe("mouseout",
            function(e) {
                this.trigger.removeClassName("clicked");
                this.trigger.stopObserving("mouseout");
            }.bindAsEventListener(this)
        );
    },
    getContent: function() {
        if (!this.content) {
            this.content = SiteExplorer.getContent();
            this.contentNode.innerHTML = this.content;
            SiteExplorer.registerEvents(this.contentNode);
            SiteExplorer.openTree(siteExplorerActivePage);
        }
    }

});

/* END: site explorer layer                                         */

var siteExplorerActivePage = 0;
Event.onDOMReady(function()
{
    var metaNames = $A(document.getElementsByTagName('meta'));
    metaNames.each(function(metaitem) {
        if(metaitem.name == 'DC.Identifier') {
            var content = metaitem.content;
            var i = content.lastIndexOf('/');
            siteExplorerActivePage = parseInt(content.substring(i+1),10);
        }
    });
    $('site-explorer').setStyle({display: 'block'});
    new sitetree();
});
    

