Exemple #1
1
 function loadAppServices($appName = SITENAME)
 {
     if (defined("BASEPATH")) {
         trigger_logikserror("App <b>'" . $appName . "'</b> has already been activated", E_ERROR);
     }
     define("BASEPATH", APPS_FOLDER . $appName . "/");
     define("APPROOT", ROOT . BASEPATH);
     define("WEBAPPROOT", SiteLocation . BASEPATH);
     if (!file_exists(APPROOT)) {
         trigger_logikserror("Site Not Found <b>'" . $appName . "'</b>", E_ERROR);
     }
     $apps_cfg = APPROOT . "apps.cfg";
     if (!file_exists($apps_cfg)) {
         trigger_logikserror("Site <b>'" . $appName . "'</b> Has Not Yet Been Activated (missing apps.cfg).", E_ERROR);
     }
     loadConfigs($apps_cfg);
     loadConfigDir(APPROOT . "config/");
     if (!defined("APPS_CONFIG_FOLDER")) {
         loadConfigs(ROOT . "config/masters/folders.cfg");
     }
     if (defined("LINGUALIZER_DICTIONARIES")) {
         Lingulizer::getInstance()->loadLocaleFile(LINGUALIZER_DICTIONARIES);
     }
     if (!defined("APPS_THEME")) {
         define("APPS_THEME", getConfig("APPS_THEME"));
     }
     if (!defined("APPS_TEMPLATEENGINE")) {
         define("APPS_TEMPLATEENGINE", getConfig("APPS_TEMPLATEENGINE"));
     }
     if (!defined("APPNAME")) {
         define("APPNAME", SITENAME);
     }
     return true;
 }
Exemple #2
0
 function _ling($data, $forceWord = false)
 {
     $ling = Lingulizer::singleton();
     if (is_array($data)) {
         foreach ($data as $a => $b) {
             $data[$a] = $ling->toLing($b);
         }
         return $data;
     } else {
         if ($forceWord) {
             return $ling->toLing($data);
         } else {
             if (strpos($data, " ") > 0) {
                 return $ling->toLingContent($data);
             } else {
                 return $ling->toLing($data);
             }
         }
     }
 }
Exemple #3
0
";
PAGE="<?php 
echo PAGE;
?>
";
UserDevice="<?php 
echo strtoupper(getUserDevice());
?>
";
UserDeviceType="<?php 
echo strtoupper(getUserDeviceType());
?>
";
LingData={};
<?php 
$ling = Lingulizer::getInstance();
$json = json_encode($ling->lang);
if (strlen($json) > 2) {
    echo 'LingData=' . $json . ';';
}
?>

function getServiceCMD(cmd,action,q) {
	return _service(cmd,action,null,q);
}
function _service(cmd,action,format,q) {
	if(cmd==null || cmd.length<=0) {
		return "";
	}
	sxx="<?php 
echo SiteLocation;