本文整理汇总了PHP中Server::isLocalServer方法的典型用法代码示例。如果您正苦于以下问题:PHP Server::isLocalServer方法的具体用法?PHP Server::isLocalServer怎么用?PHP Server::isLocalServer使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Server
的用法示例。
在下文中一共展示了Server::isLocalServer方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: generateWebmasterTools
public static function generateWebmasterTools()
{
$google=array();
$google['webmasterTools']=Configuration::getInstance()->get('Google', 'webmasterTools');
$theme = Configuration::getInstance()->get('Design', 'theme');
$tp = new templateParser(PATH."FrontEnd/".$theme."/snippets/google_webmaster_tools.htm");
if (Server::isLocalServer())
return "";
if (empty($google['webmasterTools']))
return '';
else
{
$tp->parseTemplate($google);
return $tp->display();
}
}
示例2: __construct
public function __construct()
{
/*
$this->host='db523.1und1.de';
$this->user='dbo155195156';
$this->passwd='NHEhYC9g';
$this->dbname='db155195156';
*/
$conf = Configuration::getInstance();
if (Server::isLocalServer()) {
$this->host = $conf->get('Database', 'LocalHost');
$this->user = $conf->get('Database', 'LocalUser');
$this->passwd = $conf->get('Database', 'LocalPasswd');
$this->dbname = $conf->get('Database', 'LocalDB');
$this->DBMS = $conf->get('Database', 'LocalDBMS');
$this->locktable = $conf->get('Database', 'LocalLockTable');
} else {
$this->host = $conf->get('Database', 'RemoteHost');
$this->user = $conf->get('Database', 'RemoteUser');
$this->passwd = $conf->get('Database', 'RemotePasswd');
$this->dbname = $conf->get('Database', 'RemoteDB');
$this->DBMS = $conf->get('Database', 'RemoteDBMS');
$this->locktable = $conf->get('Database', 'RemoteLockTable');
}
//$this->dbname='avaris_19_9_06';
//Data for the Article-Tables
$config = Configuration::getInstance(); //10.04.2007 MG
$this->prefix = $config->get('Database', 'DBPrefix'); //10.04.2007 MG
$this->articleTable = $this->prefix . 'articles'; //10.04.2007 MG
$this->descriptionTable = $this->prefix . 'article_descriptions'; //10.04.2007 MG
$this->parentIDTable = $this->prefix . 'article_to_parent_ids'; //10.04.2007 MG
$this->archiveTable = $this->prefix . 'article_archive';
}
示例3: __construct
public function __construct()
{
$this->data['lokal'] = Server::isLocalServer() ? 'LOKAL ' : '';
$this->data['navi_local_remote'] = Server::isLocalServer() ? 'local_navi' : 'navi';
}