I put a IFrame on a page that links to another page which you can see here...
http://raytheon.shabang.net/default.asp?page=nav&link=services
The problem is on the other page I am getting a JS error which I am not getting when i visit the page by itself. I try to insert the include file for the js into my page and I am still getting the problem. Does anyone know why the page could not be included in the IFrame without getting any JS errors? Here is the top half of the JS file so maybe you can see why it cant be included...
<!--
// page loaded var
var _pageLoaded = 0;
// Some variables governing the apperarance of menu
// items. Note that these values also appear in the CSS
// code below, so if you change these values, be sure
// to change them in both places!
// -------------------------------------
// get root based on folder name
var _folders = new Array("/about_us","/beechcraft","/contact_us","/government","/hawker","/investment","/jobs","/press","/service_support");
var _root = "";
var _location = (top.location + "").toLowerCase()
var _found = -1;
var _foundAt = 999999;
for (var r=0; r<_folders.length; r++)
if (_location.indexOf(_folders[r]) != -1 && _location.indexOf(_folders[r]) < _foundAt)
{
_found = r;
_foundAt = _location.indexOf(_folders[r]);
}
if (_found != -1)
{
_root = _location.substr(0,_foundAt) + "/";
}
// -> The width of menu items in pixels. This does not
// include its 1-pixel border, so the menu will
// actually be 2 pixels wider than this value.
if (!menuItemWidth) var menuItemWidth = 180;
if (!bmenuItemWidth) var bmenuItemWidth = 180;
if (!cmenuItemWidth) var cmenuItemWidth = 180;
// -> The height of menu items in pixels. This does
// not include the 1-pixel border between menu
// items, above the first menu item, and below the
// last menu item. Thus, the menu's height will
// actually be: ((menuItemHeight+1)*numMenuItems)+1
if (!menuItemHeight) var menuItemHeight = 19;
if (!bmenuItemHeight) var bmenuItemHeight = 19;
if (!cmenuItemHeight) var cmenuItemHeight = 19;
// The menuURLs array should contain the number of items
// in each menu. For example, if you have two menus with
// 1 menu item and 4 menu items respectively, this would
// be:
// var menuLengths = new Array(1,4);
//
// NOTE: If you only need a single menu, you can't
// use this syntax. Instead, do
// var menuLengths = new Array();
// menuLengths[0] = x;
// where x is the number of menu items.
if (!menuLengths) var menuLengths = new Array();
if (!bmenuLengths) var bmenuLengths = new Array();
if (!cmenuLengths) var cmenuLengths = new Array();
// The menuURLs 2D array should contain the URL's to be
// loaded by each menu item. Leave the following lines alone
// (they set up the empty array).
// the menu items. Be sure to keep your URLs in sync.
// Pop-up menus close after a brief delay when the user's
// mouse passes out of them. If the user's mouse returns to
// the menu before that delay expires, however, the menu
// should no longer be closed. The menuTimers array stores
// these timers for menus that are in the process of closing.
// You don't have to set anything here; the array is
// created based on the menuLengths variable you defined
// above.
var menuTimers = new Array(menuLengths.length);
var bmenuTimers = new Array(bmenuLengths.length);
var cmenuTimers = new Array(cmenuLengths.length);