//* $Revision:   1.1  $ $Date:   29 Dec 2005 17:57:50  $
//* Copyright (c) 2005-2005, Microstar Laboratories, Inc.
//* Do not copy. All rights reserved.

// Content loading services.
function HostPageCheck(APage, APath)
// Use: Set a default tab context for every page to force correct
//   history handling.
// Use: Reload a hosted page into its host document.
// See: Tabs.js for details of how the ?host tag is added to the page.
{
  document.body.DefaultTabPage = APage;
  var bPathCheck = true;
  if (APath != null)
    bPathCheck = location.pathname.indexOf(APath) != -1;
  if ((location.search.indexOf("?host=") == -1) &&
      (location.search.indexOf("&host=") == -1) && bPathCheck)
    window.location.replace(APage);
}

