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


PHP Theme::getThemeName方法代码示例

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


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

示例1: flush

 /**
  * 
  * @param Theme $theme
  * @return int id of the Theme inserted in base. False if it didn't work.
  */
 public static function flush($theme)
 {
     $themeId = $theme->getIdTheme();
     $themeName = $theme->getThemeName();
     if ($themeId > 0) {
         $sql = 'UPDATE theme SET theme_name = ? ' . 'WHERE id_theme = ?';
         $params = array('si', &$themeName, &$themeId);
     } else {
         $sql = 'INSERT INTO theme ' . '(theme_name) ' . 'VALUES(?)';
         $params = array('s', &$themeName);
     }
     $idInsert = BaseSingleton::insertOrEdit($sql, $params);
     if ($idInsert !== false && $themeId > 0) {
         $idInsert = $themeId;
     }
     return $idInsert;
 }
开发者ID:Eurymone,项目名称:Student-Exam-Report-System,代码行数:22,代码来源:ThemeDAL.php

示例2: show

 public static function show($urlKey)
 {
     // App::isLocal()
     //Récupération de tous les fichiers .json (theme.json)
     $themesHash = app_path() . '/config/assets/theme/';
     $pathForAssets = 'theme/';
     try {
         $dir = opendir($themesHash);
         $themesFile = array();
         while ($file = readdir($dir)) {
             if ($file != '.' && $file != '..' && !is_dir($themesHash . $file)) {
                 $themesFile[] = $file;
             }
         }
         closedir($dir);
     } catch (Exception $e) {
         echo 'Exception reçue : ', $e->getMessage(), "\n";
     }
     // Get theme name
     $themeName = Theme::getThemeName();
     $pathForAssets .= $themeName . '/';
     // Get file content
     $fcontent = null;
     try {
         //Lecture du fichier
         $fcontent = file_get_contents($themesHash . Theme::getThemeType() . '-' . $themeName . '.json');
         $json = json_decode($fcontent);
         $json = (array) $json;
     } catch (Exception $e) {
         echo 'Exception reçue : ', $e->getMessage(), "\n";
     }
     //retourne la valeur de la clé, si elle existe, passé en params!
     if (isset($json[$urlKey])) {
         return $pathForAssets . $json[$urlKey];
     } else {
         return $pathForAssets . $urlKey;
         return 'error_assets';
     }
 }
开发者ID:Metrakit,项目名称:dynamix,代码行数:39,代码来源:Bassets.php

示例3: base_path

<?php

/*
|--------------------------------------------------------------------------
| Register Theme
|--------------------------------------------------------------------------
|
|
*/
//Get themes
//Set namespace with override support
View::addNamespace('theme', [base_path() . '/theme/' . Theme::getThemeName() . '/views', base_path() . '/theme/default/views']);
/*
|--------------------------------------------------------------------------
| Register The Modules Providers
|--------------------------------------------------------------------------
|
|
*/
foreach (Config::get('module') as $module) {
    App::register('Dynamix\\' . $module . '\\' . $module . 'ServiceProvider');
}
/*
|--------------------------------------------------------------------------
| Register The Laravel Class Loader
|--------------------------------------------------------------------------
|
| In addition to using Composer, you may use the Laravel class loader to
| load your controllers and models. This is useful for keeping all of
| your classes in the "global" namespace without Composer updating.
|
开发者ID:Metrakit,项目名称:dynamix,代码行数:31,代码来源:global.php

示例4: Localize

require_once "../functions/errorFuncs.php";
require_once "../classes/Localize.php";
$loc = new Localize(OBIB_LOCALE, $tab);
#****************************************************************************
#*  Checking for post vars.  Go back to form if none found.
#****************************************************************************
if (count($_POST) == 0) {
    header("Location: ../admin/theme_new_form.php");
    exit;
}
#****************************************************************************
#*  Validate data
#****************************************************************************
$theme = new Theme();
$theme->setThemeName($_POST["themeName"]);
$_POST["themeName"] = $theme->getThemeName();
$theme->setTitleBg($_POST["titleBg"]);
$_POST["titleBg"] = $theme->getTitleBg();
$theme->setTitleFontFace($_POST["titleFontFace"]);
$_POST["titleFontFace"] = $theme->getTitleFontFace();
$theme->setTitleFontSize($_POST["titleFontSize"]);
$_POST["titleFontSize"] = $theme->getTitleFontSize();
$theme->setTitleFontBold(isset($_POST["titleFontBold"]));
$theme->setTitleFontColor($_POST["titleFontColor"]);
$_POST["titleFontColor"] = $theme->getTitleFontColor();
$theme->setTitleAlign($_POST["titleAlign"]);
$theme->setPrimaryBg($_POST["primaryBg"]);
$_POST["primaryBg"] = $theme->getPrimaryBg();
$theme->setPrimaryFontFace($_POST["primaryFontFace"]);
$_POST["primaryFontFace"] = $theme->getPrimaryFontFace();
$theme->setPrimaryFontSize($_POST["primaryFontSize"]);
开发者ID:vishnu35,项目名称:Granthalay,代码行数:31,代码来源:theme_new.php


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