File manager - Edit - /home/jardides/www/Jardi-design/old/administrator/components/com_templateck/views/template/tmpl/ajaxmoduleslist.php
Back
<?php /** * @name Template Creator CK 3 * @package com_templateck * @copyright Copyright (C) 2013. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt * @author Cedric Keiflin - http://www.template-creator.com - http://www.joomlack.fr */ // No direct access to this file defined('_JEXEC') or die('Restricted access'); $input = JFactory::getApplication()->input; $position = $input->get('position', '', 'string'); $type = $input->get('type', '', 'string'); $blockid = $input->get('blockid', '', 'string'); // $module = str_replace('module-', '', $type); // $module = 'mod_' . $module; $db = JFactory::getDbo(); if ($type == 'mod_menu') { $and = $type ? " AND (module='" . $type . "' OR module='mod_maximenuck')" : ""; } else { $and = $type ? " AND module='" . $type . "'" : ""; } $q = "SELECT id, title, published FROM #__modules WHERE published IN (0, 1)" . $and . " AND position='" . $position . "' AND client_id=0 ORDER BY id desc;"; try { $query = $db->getQuery(true); $db->setQuery($q); $modules = $db->loadObjectList(); } catch (Exception $e) { echo '<div class=alert><b>SQL ERROR FROM TEMPLATE CREATOR CK - LIST OF MODULES : </b>'. $e->getMessage().'</div>'; exit; } ?> <div id="ckmoduleslist"> <h3><?php echo JText::_('CK_MODULES_LIST') ?></h3> <p><?php echo JText::sprintf('CK_MODULES_LIST_DESC', '<b>' . $position . '</b>') ?></p> <p><span class="ckbutton ckbutton-success" onclick="ckAddModule('<?php echo $type ?>', '<?php echo $position ?>', '<?php echo $blockid ?>')"><span class="fa fa-plus"> </span> <?php echo JText::_('CK_CREATE_NEW') ?></span></p> <table style="width: 100%;vertical-align: middle;" class="cktable cktable-striped cktable-bordered cktable-hover"> <tr> <td colspan="1"><b><?php echo JText::_('ID') ?></b></td> <td colspan="1"><b><?php echo JText::_('CK_TITLE') ?></b></td> <td colspan="1"><b><?php echo JText::_('CK_ACTION') ?></b></td> <td colspan="1"><b><?php echo JText::_('CK_STATE') ?></b></td> </tr> <?php foreach ($modules as $module) { $publishCss = $module->published == '1' ? 'success' : 'danger'; $publishIcon = $module->published == '1' ? 'check' : 'times'; ?> <tr> <td><span class="label"><?php echo $module->id ?></span></td> <td><?php echo $module->title ?></td> <td><div class="ckbutton" onclick="ckShowModuleOptions('<?php echo $module->id ?>', 0)"><span class="fa fa-cog"> </span><?php echo JText::_('CK_EDIT') ?></div></td> <td><div class="infotip ckbutton ckbutton-small ckbutton-<?php echo $publishCss ?>" title="<?php echo JText::_('CK_TOGGLE_STATE') ?>" onclick="ckToggleModuleState(this, '<?php echo $module->id ?>')" data-state="<?php echo $module->published ?>" style="width:14px;height: 18px;"><span class="fa fa-<?php echo $publishIcon ?>"></span> </div></td> </tr> <?php } ?> </table> </div> <script> setTooltip(); </script>
| ver. 1.4 |
Github
|
.
| PHP 7.4.33 | Generation time: 0 |
proxy
|
phpinfo
|
Settings