Exemplo n.º 1
0
 public function mergeConfigs(\HTRouter\VarContainer $base, \HTRouter\VarContainer $add)
 {
     $merged = array_merge($add->get("SetEnvIf", array()), $base->get("SetEnvIf", array()));
     if (count($merged)) {
         $base->set("SetEnvIf", $merged);
     }
 }
Exemplo n.º 2
0
 public function mergeConfigs(\HTRouter\VarContainer $base, \HTRouter\VarContainer $add)
 {
     $base->set("DirectoryIndex", $add->get("DirectoryIndex") ? $add->get("DirectoryIndex") : $base->get("DirectoryIndex"));
     $base->set("DirectorySlash", $add->get("DirectorySlash") == false ? $base->get("DirectorySlash") : $add->get("DirectorySlash"));
     $base->set("FallbackResource", $add->get("FallbackResource") ? $add->get("FallbackResource") : $base->get("FallbackResource"));
 }
Exemplo n.º 3
0
 public function mergeConfigs(\HTRouter\VarContainer $base, \HTRouter\VarContainer $add)
 {
     if ($add->get("RewriteEngine", false)) {
         $base->set("RewriteEngine", $add->get("RewriteEngine"));
     }
     if ($add->get("RewriteOptions", false)) {
         $base->set("RewriteOptions", $add->get("RewriteOptions"));
     }
     if ($add->get("RewriteBase", false)) {
         $base->set("RewriteBase", $add->get("RewriteBase"));
     }
     if ($base->get("RewriteOptions", "") == "inherit") {
         $merged = array_merge($add->get("RewriteRule", array()), $base->get("RewriteRule", array()));
         if (count($merged)) {
             $base->set("RewriteRule", $merged);
         }
     } else {
         if ($add->get("RewriteRule", false)) {
             $base->set("RewriteRule", $add->get("RewriteRule"));
         }
     }
 }