tbrehm
2009-03-05 b94726392eb39dcad9c83d4732f717db90fe6f34
server/plugins-available/apache2_plugin.inc.php
@@ -332,8 +332,8 @@
               $tmp_symlink = str_replace("[website_domain]",$data["old"]["domain"],$tmp_symlink);
               // Remove trailing slash
               if(substr($tmp_symlink, -1, 1) == '/') $tmp_symlink = substr($tmp_symlink, 0, -1);
               // create the symlinks, if not exist
               if(!is_link($tmp_symlink)) {
               // remove the symlinks, if not exist
               if(is_link($tmp_symlink)) {
                  exec("rm -f ".escapeshellcmd($tmp_symlink));
                  $app->log("Removed Symlink: rm -f ".$tmp_symlink,LOGLEVEL_DEBUG);
               }
@@ -472,13 +472,13 @@
      $rewrite_rules = array();
      if($data["new"]["redirect_type"] != '') {
         $rewrite_rules[] = array(   'rewrite_domain'    => $data["new"]["domain"],
                              'rewrite_type'       => $data["new"]["redirect_type"],
                              'rewrite_type'       => ($data["new"]["redirect_type"] == 'no')?'':'['.$data["new"]["redirect_type"].']',
                              'rewrite_target'    => $data["new"]["redirect_path"]);
            
            switch($data["new"]["subdomain"]) {
            case 'www':
             $rewrite_rules[] = array(   'rewrite_domain'    => 'www.'.$data["new"]["domain"],
                                  'rewrite_type'       => $data["new"]["redirect_type"],
                                  'rewrite_type'       => ($data["new"]["redirect_type"] == 'no')?'':'['.$data["new"]["redirect_type"].']',
                                  'rewrite_target'    => $data["new"]["redirect_path"]);
                break;
            case '*':
@@ -517,12 +517,12 @@
            // Rewriting
            if($alias["redirect_type"] != '') {
               $rewrite_rules[] = array(   'rewrite_domain'    => $alias["domain"],
                                    'rewrite_type'       => $alias["redirect_type"],
                                    'rewrite_type'       => ($alias["redirect_type"] == 'no')?'':'['.$alias["redirect_type"].']',
                                    'rewrite_target'    => $alias["redirect_path"]);
                    switch($alias["subdomain"]) {
                    case 'www':
                     $rewrite_rules[] = array(   'rewrite_domain'    => 'www.'.$alias["domain"],
                                          'rewrite_type'       => $alias["redirect_type"],
                                          'rewrite_type'       => ($alias["redirect_type"] == 'no')?'':'['.$alias["redirect_type"].']',
                                          'rewrite_target'    => $alias["redirect_path"]);
                        break;
                    case '*':