Пример #1
0
 /**
  * Init objects theme module & page
  */
 private function initObjects()
 {
     $this->theme = \theme::get(\app::$request->getParam('THEMEMODULE'), \app::$request->getParam('THEME'));
     $this->module = \app::getModule(\app::$request->getParam('MODULE'));
     $IDPage = \app::$request->getParam('IDPage');
     if ($IDPage && is_numeric($IDPage)) {
         \app::$response->page = $this->page = $this->module->getPage($IDPage);
     }
 }
Пример #2
0
<?php

echo View::factory('themes/' . theme::get() . '/pages/index')->set('pages', $pages);
Пример #3
0
 /**
  * Call a method of block
  * @param string $idpage
  * @param string $theme
  * @param string $id
  * @param string $method
  * @return mixed
  */
 public function callBlockAction($idPage, $theme, $id, $method)
 {
     if (empty($theme)) {
         $blockObj =& $this->getPage($idPage)->searchBlock($id);
     } else {
         $theme = \theme::get($this->name, $theme);
         $blockObj = $theme->searchBlock($id, $theme);
     }
     if (method_exists($blockObj, $method . 'Action')) {
         return $this->callMethod($blockObj, $method . 'Action');
     }
     return FALSE;
 }
Пример #4
0
 /**
  * Set the home page
  * @Developer brandon
  * @Date Oct 11, 2010
  */
 public function home()
 {
     meta::set_title('Welcome');
     $this->template->set('content', View::factory('themes/' . theme::get() . '/home'));
 }
Пример #5
0
<?php

echo View::factory('themes/' . theme::get() . '/blogs/index_ajax')->set('blogs', $blogs);
Пример #6
0
 /**
  * Get theme name
  * @return string
  */
 public function getTheme()
 {
     /* Without theme ? */
     if ($this->theme === FALSE || \app::$request->getParam('nostructure')) {
         return '';
     }
     /* Define THEME, perm 8 = choose a theme */
     if ($_SESSION['permissions'] & 8 && isset($_COOKIE['THEME']) && isset($_COOKIE['THEMEMODULE'])) {
         return \theme::get($_COOKIE['THEMEMODULE'], $_COOKIE['THEME']);
     } else {
         if (empty($this->theme)) {
             return \theme::get(app::$config['THEMEMODULE'], app::$config['THEME']);
         } else {
             $themeParts = explode('_', $this->theme, 2);
             return \theme::get($themeParts[0], $themeParts[1]);
         }
     }
 }
Пример #7
0
<?php

echo View::factory('themes/' . theme::get() . '/products/index')->set('products', $products);
Пример #8
0
 * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
 */
app::$response->addJSFile('admin/blocks/tree/block.js', 'footer');
?>
<div id="config_tree_selector" class="none">
	<span class="spanDND sprite sprite-csspickerlittle cssblock floatleft" data-action="onDesign"></span>
	<?php 
if ($_SESSION['permissions'] & 128) {
    ?>
		<span class="floatleft ui-icon ui-icon-wrench configure_block" rel="getViewConfigBlock" data-action="onConfigure" title="<?php 
    echo t('Configuration');
    ?>
"></span>
		<?php 
    if ($_SESSION['permissions'] & 256) {
        ?>
		<span draggable="true" class="floatleft move_block ui-icon ui-icon-arrow-4"></span>
		<span class="ui-icon ui-icon-trash config_destroy floatleft" data-action="onDelete"></span>
		<?php 
    }
}
?>
</div>
<div id="tree"> 
	<?php 
$IDPage = \app::$request->getParam('IDPage');
if ($IDPage && is_numeric($IDPage)) {
    echo \app::getModule('admin')->structureTree(\theme::get(\app::$request->getParam('THEMEMODULE'), \app::$request->getParam('THEME')));
}
?>
</div>
Пример #9
0
<?php

echo View::factory('themes/' . theme::get() . '/pages/show')->set('page', $page);
Пример #10
0
<?php

echo View::factory('themes/' . theme::get() . '/errors/404');
Пример #11
0
<h2>Shopping Cart</h2>
<?php 
if (!cart::get()->cart_contents_count()) {
    ?>
	<?php 
    echo View::factory('themes/' . theme::get() . '/carts/cart_empty');
} else {
    ?>
	<table>
		<thead>
			<tr>
				<th>Product</th>
				<th>Quantity</th>
				<th>Price</th>
			</tr>
		</thead>
		<tfoot>
			<tr>
				<td colspan="2">Order Subtotal</td>
				<td><?php 
    echo format::dollar_format(cart::get()->subtotal());
    ?>
</td>
			</tr>
		</tfoot>
		<tbody>
			<?php 
    foreach (cart::get()->cart_items as $cart_item) {
        ?>
				<tr id="cart-item-<?php 
        echo $cart_item;
Пример #12
0
 /**
  * Set the view to use
  * @developer Brandon Hansen
  * @date Oct 13, 2010
  */
 public function __construct()
 {
     parent::__construct();
     $this->template = View::factory('themes/' . theme::get() . '/theme');
 }
Пример #13
0
<?php

echo View::factory('themes/' . theme::get() . '/blogs/show')->set('blog', $blog);
Пример #14
0
<?php

echo View::factory('themes/' . theme::get() . '/products/show')->set('product', $product);