Code

- French locale
[gosa.git] / vhost-apache2 / src / functions_apache.inc
index be0b3f026d47f552e3a4e9f63dd130383716ef6f..9ed7ea4b98eb552e1b3c5f548415d64fa28a92cd 100644 (file)
@@ -189,7 +189,7 @@ function getVhostDN($config,$apacheServerNameMix)
 {
   $ret = "";
   if(!strstr($apacheServerNameMix, '/')) {
-    print_red(sprintf(_("Undefined vhost name '%s'. Vhost name must look like this 'server/zone.com'."),$apacheServerNameMix));
+    print_red(sprintf(_("Undefined vhost name '%s'. Vhost name must look like this 'www.example.com or example.com'."),$apacheServerNameMix));
     return($ret);
   }
 
@@ -247,4 +247,11 @@ function getAvailableVhosts($config)
   return($zones);
 }
   
+/* Simple is domain check, it checks if the given string looks like "string.string.string"
+   or string.string */
+function GetVhostsDomain($str)
+{
+  return(preg_match("/[^\.\/]+\.[^\.\/]+$/",$str));
+}
+
 ?>