Code

Updated setup step 4 to support 100% width
[gosa.git] / setup / class_setupStep3.inc
index 18550e454decc1a6eb2cd506715ac68d73f384fd..db861f868bc12e51995b1927f2d93571ca7e4e45 100644 (file)
@@ -27,12 +27,15 @@ class setup_step_3 extends setup_step
 
   function setup_step_3()
   {
-    $this->s_title      = _("License");
-    $this->s_title_long = _("GNU / GPL-License");
-    $this->s_info       = _("GNU / GPL-License");
-      
+    $this->update_strings();
+  }
+
+  
+  function load_license()
+  {
     if(!file_exists("../setup/license.txt")){
       $this->License = "<font color='red'>License not found. Setup stops here.</font>";
+      $this->license_found = false;
     }else{
       $fp = fopen("../setup/license.txt","r");
       $this->License = "";
@@ -42,15 +45,36 @@ class setup_step_3 extends setup_step
       $this->license_found = true;
     }
   }
+
+
+  function update_strings()
+  {
+    $this->s_title      = _("License");
+    $this->s_title_long = _("GNU / GPL-License");
+    $this->s_info       = _("GNU / GPL-License");
+  }
+
  
   function execute()
   {
+    $this->load_license();
+
     $smarty = get_smarty();
-    $smarty -> assign("License",$this->License);
+    $smarty -> assign("License",nl2br($this->License));
     $smarty -> assign("license_found",$this->license_found);
+
     return($smarty -> fetch (get_template_path("../setup/setup_step3.tpl")));
   }
 
+  
+  function save_object()
+  {
+    if($this->license_found){
+      $this->is_completed = true;
+    }else{
+      $this->is_completed = false;
+    }
+  }
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: