|
Server : Apache/2.4.62 System : FreeBSD fbsdweb2.web.rcn.net 14.1-RELEASE FreeBSD 14.1-RELEASE releng/14.1-n267679-10e31f0946d8 GENERIC amd64 User : www ( 80) PHP Version : 8.3.8 Disable Function : NONE Directory : /domains/nsmd2/ |
Upload File : |
/* *************************************************
*
* � 2001 Etensity, Inc.
* Popup Window code (in JavaScript)
* basic open/close version
*
* Updated: May 7, 2001
* By: Creative Development (Vienna)
*
*************************************************** */
function popupFAQ(filename) {
// Show FAQ popup window based on features provided
faq_window = window.open( filename, "faq_window", "left=20,top=20,width=185,height=350,resizable=1,scrollbars=0,toolbar=0,status=0,location=0,directories=0,menubar=0");
faq_window.focus();
}
function popupWizard(filename) {
// Show Wizard popup window based on features provided
wizard_window = window.open( filename, "wizard_window", "left=120,top=100,width=375,height=300,resizable=1,scrollbars=1,toolbar=0,status=0,location=0,directories=0,menubar=0");
wizard_window.focus();
}
function popupSample(filename) {
// Show Sample Web Site popup window based on features provided
sample_window = window.open( filename, "sample_window", "left=120,top=100,width=670,height=560,resizable=1,scrollbars=1,toolbar=0,status=0,location=0,directories=0,menubar=0");
sample_window.focus();
}
function popupPayflow(filename) {
// Show Payflow Web Site popup window based on features provided
payflow_window = window.open( filename, "payflow_window", "left=120,top=100,width=775,height=500,resizable=1,scrollbars=1,toolbar=0,status=0,location=0,directories=0,menubar=0");
payflow_window.focus();
}
function popupHelp(filename) {
// Show Help Web Site popup window based on features provided
var browser = navigator.appName.substring(0,8);
if (browser == "Netscape")
help_window = window.open( filename, "help_window", "left=120,top=50,width=615,height=530,resizable=1,scrollbars=1,toolbar=1,status=1,location=1,directories=1,menubar=1");
else
help_window = window.open( filename, "help_window", "left=120,top=50,width=615,height=675,resizable=1,scrollbars=1,toolbar=1,status=1,location=1,directories=1,menubar=1");
help_window.focus();
}
function ClosePopup(filename) {
// Close window from itself or opener
if (!filename) {
self.close();
} else if (filename == "opener") {
if (self.opener.open && !self.opener.closed) self.opener.close();
} else {
if (filename.lastIndexOf('_window') > 0) win = filename
else win = getNameRoot(filename) + '_window';
if (eval('window.' + win + ' && ' + win + '.open && !' + win + '.closed'))
eval(win + '.close()');
}
}
function NewPage(newURL) {
// Changes main window to a new page and closes the popup
self.opener.location.href = newURL;
ClosePopup();
}
function popupTour(filename) {
// Show Tour pages in a popup
tour_window = window.open( filename, "tour_window", "left=120,top=100,width=570,height=330,resizable=1,scrollbars=1,toolbar=0,status=0,location=0,directories=0,menubar=0");
tour_window.focus();
}
function popupTry(filename) {
// Show Try It pages in a popup
try_window = window.open( filename, "try_window", "left=120,top=100,width=745,height=500,resizable=1,scrollbars=1,toolbar=1,status=0,location=0,directories=0,menubar=0");
try_window.focus();
}
function popupNameIt(filename) {
// Show Name It pages in a popup
nameit_window = window.open( filename, "nameit_window", "left=120,top=100,width=400,height=300,resizable=1,scrollbars=1,toolbar=0,status=0,location=0,directories=0,menubar=0");
nameit_window.focus();
}
function popupNameIt2(filename) {
// Show Name It pages in a popup
nameit_window = window.open( filename, "nameit_window", "left=120,top=100,width=800,height=600,resizable=1,scrollbars=1,toolbar=0,status=0,location=0,directories=0,menubar=0");
nameit_window.focus();
}
function popupShowSaving(filename) {
// Show Name It pages in a popup
nameit_window = window.open( filename, "show_window", "left=120,top=100,width=430,height=395,resizable=0,scrollbars=0,toolbar=0,status=0,location=0,directories=0,menubar=0");
nameit_window.focus();
}
function popupNewWSM(filename) {
// Show new WSM 4.0 pages in a popup
wsm_window = window.open( filename, "wsm_window", "left=120,top=100,width=459,height=411,resizable=0,scrollbars=0,toolbar=0,status=0,location=0,directories=0,menubar=0");
wsm_window.focus();
}
function popupVbizSample(filename) {
// Show vBiz sample pages in a popup with no address bar
nameit_window = window.open( filename, "vbizsample_window", "width=765,height=600,menubar=no,resizable=no,scrollbars=yes,titlebar=no,toolbar=no");
nameit_window.focus();
}
function FAQwin(url) {
var dirnum = url.indexOf("manage\-it");
var pagenum = url.indexOf("\.jhtml");
var pagename= "\/en_US\/faq\/manage-it\/FAQ-"+url.substring(dirnum+10, pagenum+6);
var browser = navigator.appName.substring(0,8);
if (browser == "Netscape")
help_window = window.open( pagename, "help_window", "left=120,top=50,width=415,height=440,resizable=1,scrollbars=1,toolbar=0,status=1,location=1,directories=0,menubar=0");
else
help_window = window.open( pagename, "help_window", "left=120,top=50,width=415,height=440,resizable=1,scrollbars=1,toolbar=0,status=1,location=1,directories=0,menubar=0");
help_window.focus();
}
function popUp(URL, type)
{
if (arguments.length == 2)
{
switch(type)
{
case "fullscreen":
width = screen.availWidth - 40;
height = screen.availHeight - 40;
break;
case "delete":
width = 400;
height = 230;
break;
case "save":
width = 450;
height = 300;
break;
case "item":
width = 640;
height = 555;
break;
case "learnmore":
width = 325;
height = 340;
break;
case "supportcenter":
width = 672;
height = 586;
break;
case "moreinfo":
width = 650;
height = 600;
break;
case "block":
width = 640;
height = 600;
break;
case "template":
width = 750;
height = 575;
break;
case "banner":
width = 780;
height = 320;
break;
case "headline":
width = 720;
height = 370;
break;
case "intuithome":
width = 780;
height = 580;
break;
case "preview":
width = 780;
height = 580;
break;
}
}
else
{
width = 550;
height = 560;
type = "generic";
}
var token = URL.indexOf('?') > -1 ? '&' : '?';
uniqueId = genUniqueId();
URL=URL+genUniqueParam(token);
var leftPosition = (screen.width - width - 20) / 2;
var topPosition = (screen.height - height) / 4;
if ((type == "supportcenter") || (type == "intuithome") || (type == "learnmore")) {
eval("win = window.open(URL, '"+type+"', 'toolbar=0,scrollbars=1,location=0,status=0,resizable=1,menubar=0,width="+width+",height="+height+"');");
} else {
eval("win = window.open(URL, '"+type+"', 'toolbar=0,scrollbars=0,location=0,status=0,resizable=1,menubar=0,width="+width+",height="+height+",left="+leftPosition+",top="+topPosition+"');");
}
if (parseInt(navigator.appVersion) >= 4)
{
win.window.focus();
}
}
// ----------------------
// Generate Unique Id
// ----------------------
function genUniqueId()
{
day = new Date();
return day.getTime();
}
// -------------------------------------------------
// Generate Unique parameter to be appended to the URL
// This will allow us to realod the HTML from the server
// -------------------------------------------------
function genUniqueParam(parameter)
{
return parameter+'unique_id='+genUniqueId();
}
function connectToSF(nextURL)
{
var sf_window = window.opener.top.top.opener;
if (sf_window == null || sf_window == '' ||
typeof sf_window == 'undefined' || sf_window.closed)
{
sf_window = window.open(nextURL, "SF_WINDOW", 'toolbar=1,scrollbars=1,location=1,status=1,menubar=1');
}
else
{
sf_window.location.href=nextURL;
}
sf_window.focus();
self.close();
}