当前位置: 首页>>代码示例>>PHP>>正文


PHP eZINI::exists方法代码示例

本文整理汇总了PHP中eZINI::exists方法的典型用法代码示例。如果您正苦于以下问题:PHP eZINI::exists方法的具体用法?PHP eZINI::exists怎么用?PHP eZINI::exists使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在eZINI的用法示例。


在下文中一共展示了eZINI::exists方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: parameterSet

 /**
  * Check whether a specified parameter in a specified section is set in a specified file
  *
  * @deprecated Since 4.4
  * @param string fileName file name (optional)
  * @param string rootDir directory (optional)
  * @param string section section name
  * @param string parameter parameter name
  * @return bool True if the the parameter is set.
  */
 static function parameterSet($fileName = 'site.ini', $rootDir = 'settings', &$section, &$parameter)
 {
     if (!eZINI::exists($fileName, $rootDir)) {
         return false;
     }
     $iniInstance = eZINI::instance($fileName, $rootDir, null, null, null, true);
     return $iniInstance->hasVariable($section, $parameter);
 }
开发者ID:runelangseid,项目名称:ezpublish,代码行数:18,代码来源:ezini.php

示例2: languageFile

 function languageFile($withVariation = false)
 {
     $type = $withVariation ? 'variation' : 'default';
     if (!$this->LanguageINI[$type] instanceof eZINI) {
         $language = $this->languageCode();
         $countryVariation = $this->countryVariation();
         $locale = $language;
         if ($withVariation) {
             if ($countryVariation !== '') {
                 $locale .= '@' . $countryVariation;
             }
         }
         $languageFile = 'language/' . $locale . '.ini';
         if (eZLocale::isDebugEnabled()) {
             eZDebug::writeNotice("Requesting {$languageFile}", __METHOD__);
         }
         if (eZINI::exists($languageFile, 'share/locale')) {
             $this->LanguageINI[$type] = eZINI::instance($languageFile, 'share/locale');
         }
     }
     return $this->LanguageINI[$type];
 }
开发者ID:legende91,项目名称:ez,代码行数:22,代码来源:ezlocale.php

示例3: array

$script->startup();

$options = $script->getOptions( '[clusterIdentifier:]', '', array(
    'clusterIdentifier' => 'Cluster\' identifier (ie : cluster_france)'
) );

$script->initialize();

if ( !isset( $options['clusterIdentifier'] ) )
{
    $script->shutdown( 1, 'clusterIdentifier must be specified' );
}

$clusterIdentifier = $options['clusterIdentifier'];

if ( !eZINI::exists( 'site.ini', "extension/{$clusterIdentifier}/settings" ) )
{
    $script->shutdown( 1, "Cluster {$clusterIdentifier} hasn't been correctly initialized. Script will shutdown now." );
}

$language = eZINI::instance( 'site.ini', "extension/{$clusterIdentifier}/settings", null, false, false, true )->variable( 'RegionalSettings', 'SiteLanguageList' );
$language = $language[0];

$user = eZUser::fetchByName( 'admin' );
$userID = $user->attribute( 'contentobject_id' );
eZUser::setCurrentlyLoggedInUser( $user, $userID );

$cli = new QuestionInteractiveCli();

$country = eZContentObject::fetchByRemoteID( 'country_' . $clusterIdentifier );
开发者ID:sushilbshinde,项目名称:ezpublish-study,代码行数:30,代码来源:build_application_tree.php


注:本文中的eZINI::exists方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。