diff options
author | vincent-peugnet <v.peugnet@free.fr> | 2019-03-31 15:38:42 +0200 |
---|---|---|
committer | vincent-peugnet <v.peugnet@free.fr> | 2019-03-31 15:38:42 +0200 |
commit | 2e27596acb55e15495492fee916304d647bb3eab (patch) | |
tree | aa7a06d0323d1c7c0bbeef7c665b61fcdcc9bb5f /app/class/config.php | |
parent | 20c44426207b8f58fd8ef1145b509913371b2901 (diff) | |
download | wcms-2e27596acb55e15495492fee916304d647bb3eab.tar.gz wcms-2e27596acb55e15495492fee916304d647bb3eab.zip |
domain analyser OG meta rendering
Diffstat (limited to 'app/class/config.php')
-rw-r--r-- | app/class/config.php | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/app/class/config.php b/app/class/config.php index 00c03ae..75081f4 100644 --- a/app/class/config.php +++ b/app/class/config.php @@ -5,6 +5,7 @@ abstract class Config { protected static $arttable = 'mystore'; + protected static $domain = ''; protected static $color4; protected static $fontsize = 15; protected static $basepath = ''; @@ -76,6 +77,22 @@ abstract class Config return (file_exists($path)); } + /** + * Calculate Domain name + */ + public static function getdomain() + { + self::$domain = $_SERVER['REQUEST_SCHEME'] . '://' . $_SERVER['HTTP_HOST']; + } + + /** + * Verify Domain name + */ + public static function checkdomain() + { + return (self::$domain === $_SERVER['REQUEST_SCHEME'] . '://' . $_SERVER['HTTP_HOST']); + } + // ________________________________________ G E T _______________________________________ public static function arttable() @@ -83,6 +100,11 @@ abstract class Config return self::$arttable; } + public static function domain() + { + return self::$domain; + } + public static function color4() { return self::$color4; @@ -177,6 +199,11 @@ abstract class Config self::$arttable = strip_tags($arttable); } + public static function setdomain($domain) + { + self::$domain = strip_tags(strtolower($domain)); + } + public static function setcolor4($color4) { if (strlen($color4) <= 8) { |