//ES REFERENCE SITE
function buildEric() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=636,height=476";
	newwindow=window.open("http://www.dayfornight.com/ericscott/index3.html","Ericscott", options);
	newwindow.document.close()
}

//ARTIST HOMEQUAYS
function buildBB() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=476,height=476";
	newwindow=window.open("../underground/lines/bluebottles/bb_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildDFN() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=576,height=476";
	newwindow=window.open("../underground/lines/dayfornight/dfn_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildES() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=525,height=476";
	newwindow=window.open("../underground/lines/ericscott/es_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildFND() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=476,height=476";
	newwindow=window.open("../underground/lines/found/fnd_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildJA() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=476,height=476";
	newwindow=window.open("../underground/ines/julieandroid/ja_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildKFM() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=476,height=476";
	newwindow=window.open("../underground/lines/kingfm/kfm_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildNF() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=526,height=476";
	newwindow=window.open("../underground/lines/nightfonts/nf_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildRF() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=476,height=476";
	newwindow=window.open("../underground/lines/rhythmfactory/rf_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildSX() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=476,height=476";
	newwindow=window.open("../underground/lines/sexus/sx_main.html","Artistpage", options);
	newwindow.document.close()
}

function buildVT() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=476,height=476";
	newwindow=window.open("../underground/lines/vontrapps/vt_main.html","Artistpage", options);
	newwindow.document.close()
}

//RX WINDOW
function givePrescription() {
	options = "toolbar=0,status=1,menubar=0,scrollbars=0," + 	"resizable=0,width=500,height=420";
	newwindow=window.open("../overground/hospital/insta-rx/index.html","Prescriptions", options);
	newwindow.document.close()}

//DYNAMICALLY generate a URL by typing a station # "001" into a TextField
// in a FORM. Note: this still does not pass the variable properly...
function createURL() {
	window.document.location.href="../underground/stations/" + station + "/index.html";
	window.document.close()
	}

//PORTFOLIO Slideshow
function buildImages() {
	options = "toolbar=0,status=0,menubar=0,scrollbars=0," + 	"resizable=0,width=400,height=400";
	newwindow=window.open("../ericscott/reference/images2.html","Portfolio", options);
	newwindow.document.close()
}

//BANKSIDE GUI buttons
function guibuttons_DoFSCommand(command, args) {
	if(command=="checkbrowser"){
		checkbrowser();
	}
}

//CHECK BROWSER MAKER & VERSION
function checkbrowser() {
	var browserName = navigator.appName.toLowerCase()
	var browserMaker = browserName.substring(0,1)
	var browserVersion = parseInt(navigator.appVersion)

	if (browserVersion >=4) {
	checkScreenSize()
	} else {
	buildSmallMenu()
	}
}

//CHECK SCREEN SIZE
function checkScreenSize() {
	if (screen.height > 480) {
	buildBigMenu()
	} else {
	buildSmallMenu()
	}
}

//(FLAWED) TUBE JOURNEY #1, REF'D FROM gateway/index.html
function TubeJourney1() {
	GetBrowserInfo();
  if (UserBrow == "NETN34") {
    for(var i=0; i<860;i=i+22){
      window.scroll(i,0)
	  }
     }
	top.window.location="../../underground/stations/019/index.html"
}


//(FLAWED) TUBE JOURNEY #2, REF'D FROM tube_ride/tunnel.html
var UserBrow = "none";
function TubeJourney2() {
	GetBrowserInfo();
  if (UserBrow == "NETN34") {
    for(var i=0; i<76500;i=i+36){
      window.scroll(i,0)
	  }
     }

window.location.href="../../stations/001/index1.html"


}

//JOURNEY WINDOW
function JourneyWindow()  { 
parent.window.close()

animWindow = window.open('../animations/connecting.html','Animation','toolbar=no,location=no,scrollbars=no,width=1000,height=668,status=yes,resizable=no,screeny=0,screenx=0')

}

//OPEN PAGE from DYNAMIC EXAMPLE...
//UNFINISHED
function openPage (domain, page)
{
// var server = "www.nightlinkrail.com";
location = "http://" + domain + server.substr (server.indexOf (".")) + "/" + page;
}


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-10742720-1");
pageTracker._trackPageview();
} catch(err) {}
