home *** CD-ROM | disk | FTP | other *** search
/ Your Business Pak / BusinessPak2.iso / Netscape / CD / as.z / asw.jar / connect2.js < prev    next >
Text File  |  1998-11-05  |  21KB  |  543 lines

  1. /* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil -*-
  2.  *
  3.  * The contents of this file are subject to the Netscape Public License
  4.  * Version 1.0 (the "NPL"); you may not use this file except in
  5.  * compliance with the NPL.  You may obtain a copy of the NPL at
  6.  * http://www.mozilla.org/NPL/
  7.  *
  8.  * Software distributed under the NPL is distributed on an "AS IS" basis,
  9.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
  10.  * for the specific language governing rights and limitations under the
  11.  * NPL.
  12.  *
  13.  * The Initial Developer of this code under the NPL is Netscape
  14.  * Communications Corporation.  Portions created by Netscape are
  15.  * Copyright (C) 1998 Netscape Communications Corporation.  All Rights
  16.  * Reserved.
  17.  */
  18. <!--  to hide script contents from old browsers
  19.  
  20.  
  21.  
  22. function configureDialer()
  23. {
  24.     netscape.security.PrivilegeManager.enablePrivilege("AccountSetup");
  25.  
  26.     var theFile = parent.parent.globals.getAcctSetupFilename(self);
  27.     var intlFlag = parent.parent.globals.GetNameValuePair(theFile,"Mode Selection","IntlMode");
  28.     intlFlag = intlFlag.toLowerCase();
  29.  
  30.  
  31.     var theFolder = parent.parent.globals.getConfigFolder(self);
  32.     theRegFile = theFolder + parent.parent.globals.document.vars.regServer.value;
  33.  
  34.  
  35.     // platform check
  36.     var thePlatform = parent.parent.globals.getPlatform();
  37.  
  38.  
  39. /*
  40.     // determine name of scripting file
  41.     var scriptEnabledFlag = parent.parent.globals.GetNameValuePair(theRegFile,"Script","ScriptEnabled");
  42.     scriptEnabledFlag = scriptEnabledFlag.toLowerCase();
  43.     var theScriptFile = "";
  44.     if (scriptEnabledFlag == "yes")    {
  45.         theScriptFile = parent.parent.globals.GetNameValuePair(theRegFile,"Script","ScriptFileName");
  46.         if (theScriptFile != null && theScriptFile != "")    {
  47.             theScriptFile = theFolder + theScriptFile;
  48.             scriptEnabledFlag = "TRUE";
  49.             }
  50.         else    {
  51.             theScriptFile="";
  52.             scriptEnabledFlag = "FALSE";
  53.             }
  54.         }
  55.     else    {
  56.         scriptEnabledFlag = "FALSE";
  57.         }
  58. */
  59.  
  60.  
  61.     // determine outside line access string
  62.     
  63.     var outsideLineAccessStr = "";
  64.     if (parent.parent.globals.document.vars.prefixData.value != "")    {
  65.         outsideLineAccessStr = parent.parent.globals.document.vars.prefixData.value;
  66.         x = outsideLineAccessStr.indexOf(",");
  67.         if (x<0)    outsideLineAccessStr = outsideLineAccessStr + ",";
  68.         }
  69.  
  70.  
  71.     // build TAPI phone number
  72.  
  73.     if (intlFlag == "yes")    {
  74.         var thePhone = parent.parent.globals.document.vars.accountPhoneNumber.value;
  75.         var theCountry = "";
  76.         var theCountryCode="";                    // XXX
  77.         var longDistanceAccess="";
  78.         var dialAsLongDistanceFlag="FALSE";
  79.         var    dialAreaCodeFlag="FALSE";
  80.         var userAreaCode="";
  81.         }
  82.     else    {
  83.         var thePhone = "(" + parent.parent.globals.document.vars.accountAreaCode.value + ") " + parent.parent.globals.document.vars.accountPhoneNumber.value;
  84.         var theCountry = "USA";
  85.         var theCountryCode="1";
  86.         var longDistanceAccess="1";                // XXX
  87.         var dialAsLongDistanceFlag="TRUE";
  88.         var    dialAreaCodeFlag="TRUE";
  89.         var userAreaCode=parent.parent.globals.document.vars.modemAreaCode.value;
  90.         if (userAreaCode == parent.parent.globals.document.vars.accountAreaCode.value)    {
  91.             dialAsLongDistanceFlag="FALSE";
  92.             dialAreaCodeFlag = "FALSE";
  93.             }
  94.  
  95.         }
  96.  
  97.  
  98.     // determine new profile name (used for Account in dialer & profile name, save info default filename)
  99.  
  100.     var    newProfileName = parent.parent.globals.document.vars.accountName.value;
  101.     if (newProfileName=="")    {
  102.         newProfileName = parent.parent.globals.document.vars.first.value;
  103.         if (parent.parent.globals.document.vars.last.value != "")    {
  104.             newProfileName = newProfileName + " " + parent.parent.globals.document.vars.last.value;
  105.             }
  106.         }
  107.     if (newProfileName!="")    newProfileName = newProfileName + "'s";
  108.     if (parent.parent.globals.document.vars.providername.value != "")    {
  109.         newProfileName = newProfileName + " " + parent.parent.globals.document.vars.providername.value;
  110.         }
  111.     newProfileName = newProfileName + " Account";
  112.     if (newProfileName.length > 240)    newProfileName=newProfileName.substring(0,240);
  113.  
  114.  
  115.     if (thePlatform == "Win16")    {
  116.         if (newProfileName.length > 40)    newProfileName=newProfileName.substring(0,40);
  117.         }
  118.  
  119.     
  120.     // On WIN32 platforms, check if newProfileName contains any invalid characters, such as '/'
  121.     // On Mac, disallow invalid characters such as ':'
  122.  
  123.     if ((thePlatform == "WinNT") || (thePlatform == "Win95")) {
  124.         var x=0;
  125.         x = newProfileName.indexOf('/');
  126.         while ((x >= 0) && (newProfileName.length != 0)) {
  127.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  128.             x = newProfileName.indexOf('/');
  129.             }
  130.         x = newProfileName.indexOf('\\');
  131.         while ((x >= 0) && (newProfileName.length != 0)) {
  132.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  133.             x = newProfileName.indexOf('\\');
  134.             }
  135.         x = newProfileName.indexOf(':');
  136.         while ((x >= 0) && (newProfileName.length != 0)) {
  137.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  138.             x = newProfileName.indexOf(':');
  139.             }
  140.         x = newProfileName.indexOf('\"');
  141.         while ((x >= 0) && (newProfileName.length != 0)) {
  142.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  143.             x = newProfileName.indexOf('\"');
  144.             }
  145.         x = newProfileName.indexOf('?');
  146.         while ((x >= 0) && (newProfileName.length != 0)) {
  147.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  148.             x = newProfileName.indexOf('?');
  149.             }
  150.         x = newProfileName.indexOf('<');
  151.         while ((x >= 0) && (newProfileName.length != 0)) {
  152.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  153.             x = newProfileName.indexOf('<');
  154.             }
  155.         x = newProfileName.indexOf('>');
  156.         while ((x >= 0) && (newProfileName.length != 0)) {
  157.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  158.             x = newProfileName.indexOf('>');
  159.             }
  160.         x = newProfileName.indexOf('|');
  161.         while ((x >= 0) && (newProfileName.length != 0)) {
  162.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  163.             x = newProfileName.indexOf('|');
  164.             }
  165.         x = newProfileName.indexOf('&');
  166.         while ((x >= 0) && (newProfileName.length != 0)) {
  167.             newProfileName = newProfileName.substring(0, x) + newProfileName.substring(x+1, newProfileName.length);
  168.             x = newProfileName.indexOf('&');
  169.             }
  170.         }
  171.     else if (thePlatform == "Macintosh")    {
  172.         var x=0;
  173.         x = newProfileName.indexOf(':');
  174.         while ((x >= 0) && (newProfileName.length != 0)) {
  175.             newProfileName = newProfileName.substring(x+1, newProfileName.length);            
  176.             x = newProfileName.indexOf(':');
  177.             }
  178.         }
  179.     else if (thePlatform == "Win31") {
  180.         var x=0;
  181.         x = newProfileName.indexOf('(');
  182.         while ((x >= 0) && (newProfileName.length != 0)) {
  183.             newProfileName = newProfileName.substring(0, x) + newProfileName.substring(x+1, newProfileName.length);
  184.             x = newProfileName.indexOf('(');
  185.             }
  186.         x = newProfileName.indexOf(')');
  187.         while ((x >= 0) && (newProfileName.length != 0)) {
  188.             newProfileName = newProfileName.substring(0, x) + newProfileName.substring(x+1, newProfileName.length);
  189.             x = newProfileName.indexOf(')');
  190.             }
  191.         }
  192.  
  193.  
  194.     // configure dialer
  195.  
  196.     dialerData = parent.parent.globals.document.setupPlugin.newStringArray(28);        // increment this # as new dialer strings are added
  197.     dialerData[0]  = "FileName=" + theRegFile;
  198.     dialerData[1]  = "AccountName=" + newProfileName;                                // parent.parent.globals.document.vars.providername.value;
  199.     dialerData[2]  = "ISPPhoneNum=" + thePhone;
  200.     dialerData[3]  = "LoginName=" + parent.parent.globals.document.vars.accountName.value;
  201.     dialerData[4]  = "Password=" + parent.parent.globals.document.vars.accountPassword.value;
  202.     dialerData[5]  = "DNSAddress=" + parent.parent.globals.document.vars.primaryDNS.value;
  203.     dialerData[6]  = "DNSAddress2=" + parent.parent.globals.document.vars.secondaryDNS.value;
  204.     dialerData[7]  = "DomainName=" + parent.parent.globals.document.vars.domainName.value;
  205.     dialerData[8]  = "IPAddress=" + parent.parent.globals.document.vars.ipAddress.value;
  206.     dialerData[9]  = "IntlMode=" + ((intlFlag=="yes") ? "TRUE":"FALSE");
  207.     dialerData[10] = "DialOnDemand=TRUE";
  208.     dialerData[11] = "ModemName=" + parent.parent.globals.document.vars.modem.value;
  209.     dialerData[12] = "ModemType=" + parent.parent.globals.document.setupPlugin.GetModemType(parent.parent.globals.document.vars.modem.value);
  210.     dialerData[13] = "DialType=" + parent.parent.globals.document.vars.dialMethod.value;
  211.     dialerData[14] = "OutsideLineAccess=" + outsideLineAccessStr;
  212.     dialerData[15] = "DisableCallWaiting=" + ((parent.parent.globals.document.vars.cwData.value != "") ? "TRUE":"FALSE");
  213.     dialerData[16] = "DisableCallWaitingCode=" + parent.parent.globals.document.vars.cwData.value;
  214.     dialerData[17] = "UserAreaCode=" + userAreaCode;
  215.     dialerData[18] = "CountryCode=" + theCountryCode;
  216.     dialerData[19] = "LongDistanceAccess=" + longDistanceAccess;
  217.     dialerData[20] = "DialAsLongDistance=" + dialAsLongDistanceFlag;
  218.     dialerData[21] = "DialAreaCode=" + dialAreaCodeFlag;
  219.     dialerData[22] = "ScriptEnabled=" + parent.parent.globals.document.vars.scriptEnabled.value;
  220.     dialerData[23] = "ScriptFileName=" + parent.parent.globals.document.vars.scriptFile.value;
  221.     dialerData[24] = "NeedsTTYWindow=" + (parent.parent.globals.document.vars.ttyWindow.checked ? "TRUE":"FALSE");                                    // XXX
  222.     dialerData[25] = "Location=Home";
  223.     dialerData[26] = "DisconnectTime=" + parent.parent.globals.GetNameValuePair(theFile,"Mode Selection","Dialer_Disconnect_After");
  224.     dialerData[27] = "Path=Existing";
  225.  
  226.  
  227.     // write out dialer data to Java Console
  228.  
  229.     if (parent.parent.globals.document.vars.debugMode.value.toLowerCase() == "yes")    {
  230.         parent.parent.globals.debug("\nDialer data (ISP: '" + parent.parent.globals.document.vars.providername.value + "'): ");
  231.         var numElements = dialerData.length;
  232.         for (var x=0; x<numElements; x++)    {
  233.             parent.parent.globals.debug("        " + x + ": " + dialerData[x]);
  234.             }
  235.         }
  236.  
  237.     parent.parent.globals.document.setupPlugin.DialerConfig(dialerData,false);
  238.  
  239.  
  240.     // configure desktop (Windows)
  241.  
  242.     var fileName = parent.parent.globals.document.vars.providerFilename.value;
  243.     var iconFilename = fileName.toUpperCase();
  244.     if (iconFilename == "")    {
  245.         iconFilename = theFolder + "DEFAULT.ICO";
  246.         }
  247.     else    {
  248.         var x = iconFilename.lastIndexOf(".NCI");
  249.         if (x>0)    {
  250.             iconFilename = iconFilename.substring(0,x) + ".ICO";
  251.             }
  252.         else    {
  253.             iconFilename = "";
  254.             }
  255.         }
  256.  
  257.     parent.parent.globals.document.setupPlugin.DesktopConfig(newProfileName, iconFilename, theFile);
  258.  
  259.  
  260.     // set up Navigator preferences
  261.  
  262.     var userName = parent.parent.globals.document.vars.first.value;
  263.     if (parent.parent.globals.document.vars.last.value != "")    {
  264.         userName = userName + " " + parent.parent.globals.document.vars.last.value;
  265.         }
  266.  
  267.     navigator.preference("network.hosts.smtp_server",        parent.parent.globals.document.vars.SMTP.value);
  268.     navigator.preference("network.hosts.nntp_server",        parent.parent.globals.document.vars.NNTP.value);
  269.  
  270.     var leaveMailOnServer = parent.parent.globals.GetNameValuePair( theFile, "Mode Selection", "Leave_On_Server" );
  271.  
  272.     parent.parent.globals.debug( "Leave_mail flag is set to " + leaveMailOnServer );
  273.  
  274.     if (leaveMailOnServer != "")
  275.     {
  276.         leaveMailOnServer = leaveMailOnServer.toLowerCase();
  277.  
  278.         if ( leaveMailOnServer == "true" )
  279.             navigator.preference( "mail.leave_on_server", true );
  280.         else if ( leaveMailOnServer == "false" )
  281.             navigator.preference( "mail.leave_on_server", false );
  282.     }
  283.  
  284.  
  285.     navigator.preference("network.hosts.pop_server",    parent.parent.globals.document.vars.mailServer.value);
  286.     if (parent.parent.globals.document.vars.mailProtocol.value.toUpperCase() == "IMAP")    {
  287.         navigator.preference("mail.server_type",            1);
  288.         }
  289.     else    {
  290.         navigator.preference("mail.server_type",            0);
  291.         }
  292.  
  293.     var mailID="";
  294.     var mailAccount = parent.parent.globals.document.vars.emailName.value;
  295.     x = mailAccount.indexOf("@");
  296.     if (x>=0)    {
  297.         mailID=mailAccount.substring(0,x);
  298.         }
  299.     else    {
  300.         mailID=mailAccount;
  301.         if (parent.parent.globals.document.vars.domainName.value != "")    {
  302.             mailAccount = mailID + "@" + parent.parent.globals.document.vars.domainName.value;
  303.             }
  304.         }
  305.  
  306.     navigator.preference("mail.pop_name",                    mailID);
  307.     navigator.preference("mail.identity.organization",        parent.parent.globals.document.vars.company.value);
  308.     navigator.preference("mail.identity.reply_to",            mailAccount);
  309.     navigator.preference("mail.identity.username",            userName);
  310.     navigator.preference("mail.identity.useremail",            mailAccount);
  311.  
  312.     navigator.preference("mail.remember_password",    false);
  313.     navigator.preference("mail.pop_password",        "");
  314.     var theMailPassword=parent.parent.globals.document.vars.emailPassword.value;
  315.     if (theMailPassword != null && theMailPassword != "")    {
  316.         theMailPassword = parent.parent.globals.document.setupPlugin.EncryptString(theMailPassword);
  317.         if (theMailPassword != null && theMailPassword != "")    {
  318.             navigator.preference("mail.remember_password",    true);
  319.             navigator.preference("mail.pop_password",        theMailPassword);
  320.             }
  321.         }
  322.  
  323.     navigator.preference("editor.author",                    userName);
  324.     navigator.preference("editor.publish_username",            parent.parent.globals.document.vars.accountName.value);
  325.     navigator.preference("editor.publish_location",            parent.parent.globals.document.vars.publishURL.value);
  326.     navigator.preference("editor.publish_browse_location",    parent.parent.globals.document.vars.viewURL.value);
  327.  
  328.     navigator.preference("editor.publish_password",            "");
  329.     navigator.preference("editor.publish_save_password",    false);
  330.     var thePublishPassword=parent.parent.globals.document.vars.publishPassword.value;
  331.     if (thePublishPassword != "")    {
  332.         thePublishPassword = parent.parent.globals.document.setupPlugin.EncryptString(thePublishPassword);
  333.         if (thePublishPassword != null && thePublishPassword != "")    {
  334.             navigator.preference("editor.publish_password",            thePublishPassword);
  335.             navigator.preference("editor.publish_save_password",    true);
  336.             }
  337.         }
  338.  
  339.  
  340.     navigator.preference("browser.mac.use_internet_config", false);
  341.  
  342.  
  343.     //var profileDir = parent.parent.globals.document.setupPlugin.GetCurrentProfileDirectory();
  344.     var profileDir = parent.parent.globals.currentProfileDirectory;
  345.     if (profileDir != null && profileDir != "")    {
  346.  
  347.         // write MUC Configuration file
  348.         var thePlatform = parent.parent.globals.getPlatform();
  349.     
  350.         var configFile="";
  351.         if ( thePlatform == "Macintosh" )                // Macintosh support
  352.             configFile = profileDir + "Configuration";
  353.         else                                            // Windows support
  354.             configFile = profileDir + "CONFIG.INI";
  355.         
  356.         parent.parent.globals.document.setupPlugin.SetNameValuePair(configFile,"Account", "Account", newProfileName);        // parent.parent.globals.document.vars.providername.value);
  357.         parent.parent.globals.document.setupPlugin.SetNameValuePair(configFile,"Modem", "Modem", parent.parent.globals.document.vars.modem.value);
  358.         parent.parent.globals.document.setupPlugin.SetNameValuePair(configFile,"Location", "Location", "Home");
  359.         
  360.  
  361.         // write out default Bookmark file (if one doesn't exist yet)
  362.         var currentBookmarkFilename="";
  363.         if ( thePlatform == "Macintosh" )                // Macintosh support
  364.             currentBookmarkFilename = profileDir + "Bookmarks.html";
  365.         else                                            // Windows support
  366.             currentBookmarkFilename = profileDir + "BOOKMARK.HTM";
  367.  
  368.         var bookmarkData = parent.parent.globals.document.setupPlugin.GetFileContents( currentBookmarkFilename );
  369.         if ( ( bookmarkData == null ) || ( bookmarkData == "" ) || ( bookmarkData.indexOf( "HREF" ) < 0 ) )
  370.         {
  371.             var defaultBookmarkFilename = parent.parent.globals.getConfigFolder( self ) + "bookmark.htm";
  372.             bookmarkData = parent.parent.globals.document.setupPlugin.GetFileContents( defaultBookmarkFilename );
  373.             if ( bookmarkData != null && bookmarkData != "" )
  374.                 parent.parent.globals.document.setupPlugin.SaveTextToFile( currentBookmarkFilename, bookmarkData, false );
  375.         }
  376.  
  377.         // copy profile lock file (if one is specified in selected .NCI file)
  378.         
  379.         theProviderFilename = parent.parent.globals.document.vars.providerFilename.value;
  380.         if (theProviderFilename != "")    {
  381.             var configLockFile = parent.parent.globals.document.setupPlugin.GetNameValuePair(theProviderFilename,"Configuration","ConfigurationFileName");
  382.             if (configLockFile != null && configLockFile != "")    {
  383.  
  384.                 // read in .CFG file (from Config folder)
  385.  
  386.                 configLockFile = theFolder + configLockFile;
  387.                 var cfgData = parent.parent.globals.document.setupPlugin.ReadFile(configLockFile);
  388.                 if (cfgData != null && cfgData != "")    {
  389.  
  390.                     // write out PROFILE.CFG file (inside of current profile directory)
  391.  
  392.                     var profileLockfilename = profileDir + "PROFILE.CFG";
  393.                     parent.parent.globals.document.setupPlugin.WriteFile(profileLockfilename,cfgData);
  394.                     }
  395.                 }
  396.             }
  397.         }
  398.  
  399.  
  400.     // rename profile
  401.  
  402.     if (thePlatform == "Macintosh") {
  403.         if (newProfileName.length > 31)    newProfileName=newProfileName.substring(0,31);
  404.         }
  405.  
  406.     parent.parent.globals.document.setupPlugin.SetCurrentProfileName(newProfileName);
  407.     if (parent.parent.globals.document.vars.debugMode.value.toLowerCase() == "yes")    {
  408.         parent.parent.globals.debug("\nSetting profile name: " + newProfileName);
  409.         }
  410. }
  411.  
  412.  
  413.  
  414. function showWindowBars()
  415. {
  416.     netscape.security.PrivilegeManager.enablePrivilege("AccountSetup");
  417.  
  418.     // check browser version
  419.     var theAgent=navigator.userAgent;
  420.     var x=theAgent.indexOf("/");
  421.     if (x>=0)    {
  422.         theVersion=theAgent.substring(x+1,theAgent.length);
  423.         x=theVersion.indexOf(".");
  424.         if (x>0)    {
  425.             theVersion=theVersion.substring(0,x);
  426.             }            
  427.         if (parseInt(theVersion)>=4)    {
  428.             top.statusbar.visible=true;
  429.             top.scrollbars.visible=true;
  430.             top.toolbar.visible=true;
  431.             top.menubar.visible=true;
  432.             top.locationbar.visible=true;
  433.             top.personalbar.visible=true;
  434.             }
  435.         }
  436.     parent.parent.globals.document.setupPlugin.SetKiosk(false);
  437. }
  438.  
  439.  
  440.  
  441. function setLocation(theURL)
  442. {
  443.     netscape.security.PrivilegeManager.enablePrivilege("AccountSetup");
  444.     
  445.     var theWindow=window.open(theURL,"__BLANK","toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes");
  446.  
  447. //    parent.parent.location.replace(theURL);                                        // jumping to the URL
  448.     top.close();
  449. }
  450.  
  451.  
  452.  
  453. function go(msg)
  454. {
  455.     netscape.security.PrivilegeManager.enablePrivilege("AccountSetup");
  456.  
  457.     if (msg=="Connect Now")    {
  458.  
  459.         if (parent.parent.globals.document.vars.editMode.value != "yes")    {
  460.             configureDialer();
  461.  
  462.             if (parent.parent.globals.document.setupPlugin.NeedReboot() == true)    {
  463.                 parent.parent.globals.forceReboot("connect2.htm");                // XXX hardcode in name of next screen???
  464.                 return(false);
  465.                 }
  466.  
  467.             if (parent.parent.globals.document.setupPlugin.DialerConnect() == false)    {
  468.                 window.location.replace("error.htm");                            // XXX hardcode in name of next screen???
  469.                 return(false);
  470.                 }
  471.     
  472. //            showWindowBars();
  473.     
  474.             var theFile = parent.parent.globals.getAcctSetupFilename(self);
  475.             var theURL = parent.parent.globals.GetNameValuePair(theFile,"Existing Acct Mode","RegPodURL");
  476.             if (theURL == null || theURL == "")    {
  477.                 theURL = "http://home.netscape.com/";
  478.                 }
  479.             setTimeout("setLocation(\'" + theURL + "\')", 1000);
  480.             }
  481.         else    {
  482.             alert("You cannot connect while in edit mode.");
  483.             return(false);
  484.             }
  485.         }
  486.     else if (msg == "error.htm")    {
  487.         if (parent.parent.globals.document.vars.editMode.value == "yes")    {    // only do this if editMode is false
  488.                 return (confirm("Since you are in edit mode, would you like to edit the error screen that users will see if the connection fails?"));
  489.                 }
  490.         else    {
  491.             return(false);
  492.             }
  493.         }
  494.     else if ((msg=="Later") && (parent.parent.globals.document.vars.editMode.value != "yes"))    {    
  495.         configureDialer();
  496.         //showWindowBars();
  497.         return(true);
  498.         }
  499.     else if (msg=="Back")    {
  500.         history.back();
  501.         }
  502.     return(false);
  503. }
  504.  
  505.  
  506.  
  507. function checkData()
  508. {
  509.     return(true);
  510. }
  511.  
  512.  
  513.  
  514. function doGo()
  515. {
  516.     netscape.security.PrivilegeManager.enablePrivilege("AccountSetup");
  517.     parent.controls.go("Next");
  518. }
  519.  
  520.  
  521.  
  522. function loadData()
  523. {
  524.     netscape.security.PrivilegeManager.enablePrivilege("AccountSetup");
  525.  
  526.     if (parent.parent.globals.document.vars.tryAgain.value == "yes")    {
  527.         parent.parent.globals.document.vars.tryAgain.value = "no";
  528.         setTimeout("doGo()",1);
  529.         }
  530.  
  531.     if (parent.controls.generateControls)    parent.controls.generateControls();
  532. }
  533.  
  534.  
  535.  
  536. function saveData()
  537. {
  538. }
  539.  
  540.  
  541.  
  542. // end hiding contents from old browsers  -->
  543.