Ignore:
Timestamp:
2009-04-15T14:53:44+12:00 (15 years ago)
Author:
ak19
Message:

Updated several files so that the Server2 code in server.jar interacts with GLI code so that the local GS2 server for Linux works the same way as the GS2 Local Library Server on windows

File:
1 edited

Legend:

Unmodified
Added
Removed
  • greenstone3/trunk/src/java/org/greenstone/server/BaseServerSettings.java

    r18868 r18969  
    6060    }
    6161
    62     String auto_start_str = server.config_properties.getProperty(BaseServer.Property.AUTOSTART);
    63     if ((auto_start_str.trim()).equals("true")) {
     62    String auto_start_str = server.config_properties.getProperty(BaseServer.Property.AUTOSTART).trim();
     63    if (auto_start_str.equals("true") || auto_start_str.equals("1")) {
    6464        this.autoStart = true;
    6565    } else {
     
    272272        newFileLines = scriptReadWrite.queryReplace(oldFileLines, BaseServer.Property.WEB_PORT, portNum+"");
    273273       
    274         String newAutoEnter = (new Boolean(autoEnter.isSelected())).toString();
    275         newFileLines = scriptReadWrite.queryReplace(newFileLines, BaseServer.Property.AUTOSTART, newAutoEnter);
    276        
    277274        // call the subclass' save() method to save custom elements
    278275        save(scriptReadWrite, newFileLines);
     
    287284                         newFileLines);
    288285        server.reloadConfigProperties();
     286        server.reload(); // work out the URL again in case it has changed
    289287        if (require_restart){
    290288            JOptionPane.showMessageDialog(null,server.dictionary.get("ServerSetting.SettingChanged"),"Info", JOptionPane.INFORMATION_MESSAGE);
     289            if(autoStart) {
     290            server.autoStart();
     291            server.getServerControl().updateControl();
     292            }
    291293        }
    292294        }
Note: See TracChangeset for help on using the changeset viewer.