//New Javascript file for cs-east internal web site
//located @ \\sparky\cs-east\new
//Author: Michael Nesta
//Date: 7/7/2009

//Links functions

//Function name: link_open(theLink)
//Parameters: theLink = file (and if necessary, full path) that is 
//            be opened

function link_open(which)
{
	//alert('The variable contains ' + $theLink);
	window.open(which);
}

/*function link_open($theLink)
{
	window.open($theLink);
}*/

//Function name: pic_open($imagePath)
//Parameters: imagePath = pathname for image to be loaded
function pic_open($imagePath)
{
	$theImage = new Image();
	$theImage.src = ($imagePath);
	view_image($theImage);
}


//Function name: view_image($theImage)
//Parameters: theImage = the preloaded image to be viewed
function view_image($theImage)
{
	window.open("image.html?" + $theImage , "", "resizable=1, height=200, width=200");

}

//The following functions all open different sized pop ups for sales
//pages.  I left them as they were from the older corpie.js file that
//was in use as they are sufficient and are not harsh on performance
//
//Parameters: which = the url for the page that will populate the new window
function sale_open(which){
sale = window.open(which,"","width=610,height=300,menubar=0,toolbar=0,status=0,address=0,resizable=0");
}

function sale_open_bigger(which){
sale = window.open(which,"","width=610,height=600,menubar=0,toolbar=0,status=0,address=0,resizable=0");
}

function sale_open_1(which){
sale = window.open(which,"","width=610,height=350,menubar=0,toolbar=0,status=0,address=0,resizable=0");
}

function sale_open_re(which){
sale = window.open(which,"","width=610,height=300,menubar=0,toolbar=0,status=0,address=0,resizable=0");
}

function sale_open_omni(which){
sale = window.open(which,"","width=610,height=200,menubar=0,toolbar=0,status=0,address=0,resizable=0");
}

function sale_open_omni_first(which){
sale = window.open(which,"","width=610,height=475,menubar=0,toolbar=0,status=0,address=0,resizable=0");
}

//Function name: sale_close(which)
//Parameter: which = the url for the page that will be closed
//this function closes a window that was popped up
function sale_close(which){
window.close(which);
}

//Function name: pr_release_open(which)
//Parameter: which = the url for the page that will populate the new window
//This function opens a link on the ie_press.shtml page in a specific format 
function pr_release_open(which){
window.open(which,"","width=800,height=500,menubar=1,toolbar=1,status=0,address=1,resizable=1,scrollbars=1");
}	

function map_open(){
window.open("ie_map.html","","width=650,height=500,menubar=0,toolbar=0,status=0,address=0,resizable=0");
}
