本文整理匯總了PHP中Wind::getAppName方法的典型用法代碼示例。如果您正苦於以下問題:PHP Wind::getAppName方法的具體用法?PHP Wind::getAppName怎麽用?PHP Wind::getAppName使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Wind
的用法示例。
在下文中一共展示了Wind::getAppName方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: onCreate
public function onCreate()
{
Wekit::createapp(Wind::getAppName());
$_debug = Wekit::C('site', 'debug');
if ($_debug == !Wind::$isDebug) {
Wind::$isDebug = $_debug;
}
error_reporting($_debug ? E_ALL ^ E_NOTICE ^ E_DEPRECATED : E_ERROR | E_PARSE);
set_error_handler(array($this->front, '_errorHandle'), error_reporting());
$this->_convertCharsetForAjax();
if ($components = Wekit::C('components')) {
Wind::getApp()->getFactory()->loadClassDefinitions($components);
}
}
示例2: onCreate
public function onCreate()
{
if (in_array(Wind::getAppName(), array('phpwind', 'pwadmin'))) {
//雲應用監聽sql執行
WindFactory::_getInstance()->loadClassDefinitions(array('sqlStatement' => array('proxy' => 'WIND:filter.proxy.WindEnhancedClassProxy', 'listeners' => array('LIB:compile.acloud.PwAcloudDbListener'))));
}
if (!is_file(Wind::getRealPath('DATA:install.lock', true))) {
Wind::getApp()->getResponse()->sendRedirect("install.php");
}
Wekit::createapp(Wind::getAppName());
$_debug = Wekit::C('site', 'debug');
if ($_debug == !Wind::$isDebug) {
Wind::$isDebug = $_debug;
}
if ('phpwind' == Wind::getAppName()) {
error_reporting($_debug ? E_ALL ^ E_NOTICE ^ E_DEPRECATED : E_ERROR | E_PARSE);
set_error_handler(array($this->front, '_errorHandle'), error_reporting());
}
$this->_convertCharsetForAjax();
if ($components = Wekit::C('components')) {
Wind::getApp()->getFactory()->loadClassDefinitions($components);
}
}
示例3: resolvedPath
/**
* 解析資源文件路徑信息
*
* @param string $package
* @return string
*/
protected function resolvedPath($package)
{
$this->path || ($this->path = Wind::getRootPath(Wind::getAppName()));
$this->language || ($this->language = $this->getRequest()->getAcceptLanguage());
$path = $this->path . '/' . $this->language . '/' . strtolower($package);
$path = Wind::getRealDir(trim($path, '/'), true);
return $path;
}
示例4: getTokenName
/**
* token名稱處理
*
* @param string $tokenName
* @return string
*/
protected function getTokenName($tokenName)
{
$tokenName || ($tokenName = Wind::getAppName());
return substr(md5('_token' . $tokenName . '_csrf'), -16);
}