init scripts: Fix bug with writing PID files
[hcoop/domtool2.git] / src / plugins / apache.sml
index 300ffa4..450cfbb 100644 (file)
@@ -977,7 +977,17 @@ val () = Env.action_one "diskCache"
         (fn path => (write "\tCacheEnable disk \"";
                      write path;
                      write "\"\n"))
-        
+
+val php_version = fn (EVar "php4", _) => SOME 4
+                  | (EVar "php5", _) => SOME 5
+                  | _ => NONE
+
+val () = Env.action_one "phpVersion"
+        ("version", php_version)
+        (fn version => (write "\tAddHandler x-httpd-php";
+                        write (Int.toString version);
+                        write " .php .phtml\n"))
+
 val () = Domain.registerResetLocal (fn () =>
                                       ignore (OS.Process.system (Config.rm ^ " -rf /var/domtool/vhosts/*")))