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


PHP Theme::GetConfig方法代码示例

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


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

示例1: Step1

 public function Step1()
 {
     Theme::Set('form_action', 'index.php?p=upgrade');
     // Check environment
     $config = new Config();
     $environment = $config->CheckEnvironment();
     $formFields = array();
     $formButtons = array();
     $formFields[] = FormManager::AddMessage(sprintf(__('First we need to re-check if your server meets %s\'s requirements. The CMS requirements may change from release to release. If this is the case there will be further information in the release notes.'), Theme::GetConfig('app_name')));
     $formFields[] = FormManager::AddRaw($environment);
     if ($config->EnvironmentFault()) {
         $formFields[] = FormManager::AddHidden('step', 1);
         $formButtons[] = FormManager::AddButton(__('Retest'));
     } else {
         if ($config->EnvironmentWarning()) {
             $formFields[] = FormManager::AddHidden('step', 2);
             $formButtons[] = FormManager::AddButton(__('Retest'), 'link', 'index.php?p=upgrade&step=1');
             $formButtons[] = FormManager::AddButton(__('Next'));
         } else {
             $formFields[] = FormManager::AddHidden('step', 2);
             $formButtons[] = FormManager::AddButton(__('Next'));
         }
     }
     // Return a rendered form
     Theme::Set('form_fields', $formFields);
     Theme::Set('form_buttons', $formButtons);
     return Theme::RenderReturn('form_render');
 }
开发者ID:fignew,项目名称:xibo-cms,代码行数:28,代码来源:upgrade.class.php

示例2: defined

 *
 * Xibo is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with Xibo.  If not, see <http://www.gnu.org/licenses/>.
 */
defined('XIBO') or die("Sorry, you are not allowed to directly access this page.<br /> Please press the back button in your browser.");
?>
<!DOCTYPE html>
<html lang="en">
	<head>
		<title><?php 
echo Theme::GetConfig('theme_title');
?>
</title>
		<meta name="viewport" content="width=device-width, initial-scale=1.0">
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		<link rel="shortcut icon" href="<?php 
echo Theme::ImageUrl('favicon.ico');
?>
" />

		<link href="theme/default/libraries/bootstrap/css/bootstrap.min.css" rel="stylesheet" media="screen">
		<link href="theme/default/libraries/bootstrap/css/bootstrap-responsive.min.css" rel="stylesheet">
		<link href="theme/default/libraries/bootstrap/css/bootstrap-datetimepicker.min.css" rel="stylesheet">
		<link href="theme/default/libraries/jquery/jquery.tablesorter.pager.css" rel="stylesheet">
		<link href="theme/default/libraries/jquery/jquery-ui/css/ui-lightness/jquery-ui-1.10.2.custom.min.css" rel="stylesheet">
		<link href="theme/default/libraries/jquery-file-upload/css/jquery.fileupload-ui.css" rel="stylesheet">
开发者ID:abbeet,项目名称:server39,代码行数:31,代码来源:header.php

示例3: Step8

 public function Step8()
 {
     PDOConnect::init();
     // Define the VERSION
     Config::Version();
     Theme::Set('form_action', 'index.php?q=login');
     Theme::Set('about_url', 'index.php?p=index&q=About');
     Theme::Set('source_url', Theme::SourceLink());
     // Message (either from the URL or the session)
     Theme::Set('login_message', sprintf(__("%s was successfully installed. Please log-in with the user details you chose earlier."), Theme::GetConfig('app_name')));
     Theme::Render('login_page');
     // Install files
     Media::installAllModuleFiles();
     // Delete install
     if (!unlink('install.php')) {
         throw new Exception(__("Unable to delete install.php. Please ensure the webserver has permission to unlink this file and retry"));
     }
     exit;
 }
开发者ID:fignew,项目名称:xibo-cms,代码行数:19,代码来源:install.class.php

示例4:

" target="_blank"><?php 
echo Theme::Translate('Read more');
?>
</a>
                        </div>
                    </div>
                </div>
                <div class="item">
                    <img src="theme/default/img/screenshots/calendar_screenshot.png" alt="Slide 3">
                    <div class="carousel-caption">
                        <h3><?php 
echo Theme::Translate('Schedule');
?>
</h3>
                        <p><?php 
echo Theme::Translate('Send something down to your display and watch %s come alive! Create events on Displays / Groups for Layouts / Campaigns, create repeat events and much more.', Theme::GetConfig('app_name'));
?>
</p>
                        <div class="btn-group">
                            <a class="btn btn-primary btn-lg" role="button" href="index.php?p=schedule"><?php 
echo Theme::Translate('Schedule Event');
?>
</a>
                            <a class="btn btn-default btn-lg" role="button" href="<?php 
echo HelpManager::Link('Schedule', 'General');
?>
" target="_blank"><?php 
echo Theme::Translate('Read more');
?>
</a>
                        </div>
开发者ID:fignew,项目名称:xibo-cms,代码行数:31,代码来源:new_user_welcome.php

示例5:

?>
<br />
Copyright &copy 2006-2014 Daniel Garner, Alex Harrington, Spring Signage Ltd and 
the <a target="_blank"  href="https://launchpad.net/~xibo-developers/+members" title="Xibo Developers">Xibo Developers</a>.</p>
 
<p>Xibo is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
any later version. </p>
 
<p>Xibo is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Affero General Public License for more details.</p>
 
<p>You should have received a copy of the GNU Affero General Public License
along with Xibo. If not, see <a target="_blank" href="http://opensource.org/licenses/AGPL-3.0">opensource.org/licenses/AGPL-3.0</a>. </p>

<h2>Source Code</h2>
<p>As an end user of the Xibo software you are entitled to download and view the source code. You may do 
	so from <a target="_blank"  id="source-link" href="<?php 
echo Theme::GetConfig('cms_source_url');
?>
">GitHub</a>.
	As a service provider you <strong>MUST</strong> provide your end users notification of and access to the source code.</p>

<h2>Third Party Licenses</h2>
<p>Xibo uses some third party libraries and tools - these are provided with the software under licences compatible with the AGPLv3. All licences for 
	third party libraries are included with that library and attributed in the code.</p>

<p>Xibo is supported and maintained by <a target="_blank"  href="http://springsignage.com/" title="Xibo Commercial Sponsor">Spring Signage Ltd</a>.</p>
开发者ID:fignew,项目名称:xibo-cms,代码行数:31,代码来源:about_text.php

示例6:

" />
  </head>

	<body>

	    <div class="container">

			<form class="form-signin text-center" action="<?php 
echo Theme::Get('form_action');
?>
" method="post">
        <?php 
echo Theme::Get('form_meta');
?>
        <p><a href="<?php 
echo Theme::GetConfig('theme_url');
?>
"><img src='<?php 
echo Theme::ImageUrl('xibologo.png');
?>
'></a></p>

        <p><?php 
echo Theme::Translate('Please provide your credentials');
?>
</p>

        <input name="username" type="text" class="input-block-level" placeholder="<?php 
echo Theme::Translate('User');
?>
" autofocus>
开发者ID:abbeet,项目名称:server39,代码行数:31,代码来源:login_page.php

示例7: sprintf

    ?>
<div class="jumbotron">
        <div class="container">
        <h1><?php 
    echo Theme::Translate('Welcome to the %s Upgrade!', Theme::GetConfig('app_name'));
    ?>
</h1>
        <p><?php 
    echo sprintf(Theme::Translate('Thank you for upgrading %s. This upgrade wizard will take you through the %s upgrade process one step at a time. There are only 2 steps, the first one is below.'), Theme::GetConfig('app_name'), Theme::GetConfig('app_name'));
    ?>
</p>
        <p><?php 
    echo Theme::Translate('Please read through the release notes before you begin as they contain important information about this new release.');
    ?>
</p>
        <p><a class="btn btn-primary btn-lg" role="button" href="<?php 
    echo Theme::GetConfig('cms_release_notes_url');
    ?>
" target="_blank"><?php 
    echo sprintf(Theme::Translate('Release Notes %s'), '&raquo;');
    ?>
</a></p>
        </div>
</div>
<?php 
} else {
    ?>
<h1 class="page-header">Upgrade</h1>
<?php 
}
echo Theme::Get('page_content');
开发者ID:fignew,项目名称:xibo-cms,代码行数:31,代码来源:upgrade_page.php

示例8: displayPage


//.........这里部分代码省略.........
         Theme::Set('xmdsLimitSet', $xmdsLimit > 0);
         Theme::Set('bandwidthSuffix', $suffixes[$base]);
         Theme::Set('bandwidthWidget', json_encode($output));
         // We would also like a library usage pie chart!
         $libraryLimit = Config::GetSetting('LIBRARY_SIZE_LIMIT_KB');
         $libraryLimit = $libraryLimit * 1024;
         // Library Size in Bytes
         $sth = $dbh->prepare('SELECT IFNULL(SUM(FileSize), 0) AS SumSize, type FROM media GROUP BY type;');
         $sth->execute();
         $results = $sth->fetchAll();
         // Do we base the units on the maximum size or the library limit
         $maxSize = 0;
         if ($libraryLimit > 0) {
             $maxSize = $libraryLimit;
         } else {
             // Find the maximum sized chunk of the items in the library
             foreach ($results as $library) {
                 $maxSize = $library['SumSize'] > $maxSize ? $library['SumSize'] : $maxSize;
             }
         }
         // Decide what our units are going to be, based on the size
         $base = $maxSize == 0 ? 0 : floor(log($maxSize) / log(1024));
         $output = array();
         $totalSize = 0;
         foreach ($results as $library) {
             $output[] = array('value' => round((double) $library['SumSize'] / pow(1024, $base), 2), 'label' => ucfirst($library['type']));
             $totalSize = $totalSize + $library['SumSize'];
         }
         // Do we need to add the library remaining?
         if ($libraryLimit > 0) {
             $remaining = round(($libraryLimit - $totalSize) / pow(1024, $base), 2);
             $output[] = array('value' => $remaining, 'label' => __('Free'));
         }
         // What if we are empty?
         if (count($output) == 0) {
             $output[] = array('label' => __('Empty'), 'value' => 0);
         }
         Theme::Set('libraryLimitSet', $libraryLimit);
         Theme::Set('libraryLimit', round((double) $libraryLimit / pow(1024, $base), 2) . ' ' . $suffixes[$base]);
         Theme::Set('librarySize', Kit::formatBytes($totalSize, 1));
         Theme::Set('librarySuffix', $suffixes[$base]);
         Theme::Set('libraryWidget', json_encode($output));
         // Also a display widget
         $sort_order = array('display');
         $displays = $this->user->DisplayList($sort_order);
         $rows = array();
         if (is_array($displays) && count($displays) > 0) {
             // Output a table showing the displays
             foreach ($displays as $row) {
                 $row['mediainventorystatus'] = $row['mediainventorystatus'] == 1 ? 'success' : ($row['mediainventorystatus'] == 2 ? 'danger' : 'warning');
                 // Assign this to the table row
                 $rows[] = $row;
             }
         }
         Theme::Set('display-widget-rows', $rows);
         // Get a count of users
         $sth = $dbh->prepare('SELECT IFNULL(COUNT(*), 0) AS count_users FROM `user`');
         $sth->execute();
         Theme::Set('countUsers', $sth->fetchColumn(0));
         // Get a count of active layouts
         $sth = $dbh->prepare('SELECT IFNULL(COUNT(*), 0) AS count_scheduled FROM `schedule_detail` WHERE :now BETWEEN FromDT AND ToDT');
         $sth->execute(array('now' => time()));
         Theme::Set('nowShowing', $sth->fetchColumn(0));
         // Latest news
         if (Config::GetSetting('DASHBOARD_LATEST_NEWS_ENABLED') == 1) {
             // Make sure we have the cache location configured
             Kit::ClassLoader('file');
             $file = new File($this->db);
             File::EnsureLibraryExists();
             // Use SimplePie to get the feed
             include_once '3rdparty/simplepie/autoloader.php';
             $feed = new SimplePie();
             $feed->set_cache_location($file->GetLibraryCacheUri());
             $feed->set_feed_url(Theme::GetConfig('latest_news_url'));
             $feed->set_cache_duration(86400);
             $feed->handle_content_type();
             $feed->init();
             $latestNews = array();
             if ($feed->error()) {
                 Debug::LogEntry('audit', 'Feed Error: ' . $feed->error(), get_class(), __FUNCTION__);
             } else {
                 // Store our formatted items
                 foreach ($feed->get_items() as $item) {
                     $latestNews[] = array('title' => $item->get_title(), 'description' => $item->get_description(), 'link' => $item->get_link());
                 }
             }
             Theme::Set('latestNews', $latestNews);
         } else {
             Theme::Set('latestNews', array(array('title' => __('Latest news not enabled.'), 'description' => '', 'link' => '')));
         }
     } catch (Exception $e) {
         Debug::LogEntry('error', $e->getMessage());
         // Show the error in place of the bandwidth chart
         Theme::Set('widget-error', 'Unable to get widget details');
     }
     // Do we have an embedded widget?
     Theme::Set('embedded-widget', html_entity_decode(Config::GetSetting('EMBEDDED_STATUS_WIDGET')));
     // Render the Theme and output
     Theme::Render('status_dashboard');
 }
开发者ID:fignew,项目名称:xibo-cms,代码行数:101,代码来源:statusdashboard.class.php


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