Commit d36407aac297b175183aa91c6c2fc22ed007faa8

Authored by Conrad Vermeulen
1 parent 2fc4c280

KTS-3136

"Implement Open Search with new search"
Fixed.

Committed By: Conrad Vermeulen
Reviewed By: Megan Watson

git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@8237 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing 1 changed file with 9 additions and 1 deletions
lib/util/ktutil.inc
... ... @@ -49,6 +49,14 @@ class KTUtil {
49 49 const TB = 1099511627776;
50 50 const PB = 1125899906842624;
51 51  
  52 + static function kt_url()
  53 + {
  54 + global $default;
  55 +
  56 + return ($default->sslEnabled ? 'https' : 'http') .'://'.$_SERVER['HTTP_HOST'] . $default->rootUrl;
  57 +
  58 + }
  59 +
52 60 static function computePeriod($diff, $suffix = null, $returnArray=false)
53 61 {
54 62 if (is_null($suffix))
... ... @@ -229,7 +237,7 @@ class KTUtil {
229 237 if (!is_array($aArray)) {
230 238 $aArray = (array) $aArray;
231 239 }
232   -
  240 +
233 241 if ($aArray !== 0 && $aArray !== '0' && empty($aArray)) {
234 242 return $mDefault;
235 243 }
... ...