first commit
This commit is contained in:
@@ -0,0 +1 @@
|
||||
<html><body bgcolor="#FFFFFF"></body></html>
|
||||
@@ -0,0 +1,88 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2020. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
defined('_JEXEC') or die;
|
||||
?>
|
||||
<nav id="context-menu-ck" class="context-menu-ck">
|
||||
<ul class="context-menu-ck__items">
|
||||
<li class="context-menu-ck__item context-menu-ck_row parent" data-target="row">
|
||||
<a href="#" class="context-menu-ck__link" data-action="parentItem"><i class="fa fa-ellipsis-h"></i> <?php echo JText::_('CK_ROW') ?></a>
|
||||
<ul class="context-menu-ck__items">
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="row.edit"><i class="fa fa-pencil-square-o"></i> <?php echo JText::_('CK_EDIT_STYLES') ?></a>
|
||||
<a href="#" class="context-menu-ck__link context-menu-ck__item-styles-copy" data-action="row.stylecopy"><i class="fa fa-copy"></i> </a>
|
||||
<a href="#" class="context-menu-ck__link context-menu-ck__item-styles-paste" data-action="row.stylepaste"><i class="fa fa-paste"></i> </a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="row.columns"><i class="fa fa-align-justify"></i> <?php echo JText::_('CK_EDIT_COLUMNS') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="row.fullwidth"><i class="fa fa-expand"></i> <?php echo JText::_('CK_FULLWIDTH') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="row.duplicate"><i class="fa fa-clone"></i> <?php echo JText::_('CK_DUPLICATE_ROW') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="row.favorite"><i class="fa fa-magic"></i> <?php echo JText::_('CK_DESIGN_SUGGESTIONS') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="row.save"><i class="fa fa-floppy-o"></i> <?php echo JText::_('CK_SAVE') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="row.remove"><i class="fa fa-times"></i> <?php echo JText::_('CK_REMOVE_ROW') ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="context-menu-ck__item context-menu-ck_column parent" data-target="column">
|
||||
<a href="#" class="context-menu-ck__link" data-action="parentItem"><i class="fa fa-columns"></i> <?php echo JText::_('CK_COLUMN') ?></a>
|
||||
<ul class="context-menu-ck__items">
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="column.edit"><i class="fa fa-pencil-square-o"></i> <?php echo JText::_('CK_EDIT_STYLES') ?></a>
|
||||
<a href="#" class="context-menu-ck__link context-menu-ck__item-styles-copy" data-action="column.stylecopy"><i class="fa fa-copy"></i> </a>
|
||||
<a href="#" class="context-menu-ck__link context-menu-ck__item-styles-paste" data-action="column.stylepaste"><i class="fa fa-paste"></i> </a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="column.duplicate"><i class="fa fa-clone"></i> <?php echo JText::_('CK_DUPLICATE_COLUMN') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="column.favorite"><i class="fa fa-magic"></i> <?php echo JText::_('CK_DESIGN_SUGGESTIONS') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="column.remove"><i class="fa fa-times"></i> <?php echo JText::_('CK_REMOVE_BLOCK') ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="context-menu-ck__item context-menu-ck_item parent" data-target="item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="parentItem"><i class="fa fa-window-maximize"></i> <?php echo JText::_('CK_ITEM') ?></a>
|
||||
<ul class="context-menu-ck__items">
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="item.edit"><i class="fa fa-pencil-square-o"></i> <?php echo JText::_('CK_EDIT_ITEM') ?></a>
|
||||
<a href="#" class="context-menu-ck__link context-menu-ck__item-styles-copy" data-action="item.stylecopy"><i class="fa fa-copy"></i> </a>
|
||||
<a href="#" class="context-menu-ck__link context-menu-ck__item-styles-paste" data-action="item.stylepaste"><i class="fa fa-paste"></i> </a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="item.duplicate"><i class="fa fa-clone"></i> <?php echo JText::_('CK_DUPLICATE_ITEM') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="item.favorite"><i class="fa fa-magic"></i> <?php echo JText::_('CK_DESIGN_SUGGESTIONS') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="item.save"><i class="fa fa-floppy-o"></i> <?php echo JText::_('CK_SAVE') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="item.clearstyles"><i class="fa fa-paint-brush"></i> <?php echo JText::_('CK_CLEAR_STYLES') ?></a>
|
||||
</li>
|
||||
<li class="context-menu-ck__item">
|
||||
<a href="#" class="context-menu-ck__link" data-action="item.remove"><i class="fa fa-times"></i> <?php echo JText::_('CK_REMOVE_ITEM') ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</nav>
|
||||
<link rel="stylesheet" href="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/ckcontextmenu.css?ver=<?php echo PAGEBUILDERCK_VERSION ?>" type="text/css" />
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/ckcontextmenu.js?ver=<?php echo PAGEBUILDERCK_VERSION ?>" type="text/javascript"></script>
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
$user = JFactory::getUser();
|
||||
$app = JFactory::getApplication();
|
||||
|
||||
$assoc = isset($app->item_associations) ? $app->item_associations : 0;
|
||||
$canEdit = $user->authorise('core.edit', 'com_pagebuilderck');
|
||||
|
||||
// loads the css and js files
|
||||
require PAGEBUILDERCK_PATH . '/views/page/tmpl/include.php';
|
||||
// loads the main content
|
||||
require PAGEBUILDERCK_PATH . '/views/page/tmpl/main.php';
|
||||
// loads the context menu
|
||||
//require PAGEBUILDERCK_PATH . '/views/page/tmpl/contextmenu.php';
|
||||
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
?>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,250 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Pagebuilderck\CKFof;
|
||||
|
||||
if (!defined('PAGEBUILDERCK_MEDIA_URI'))
|
||||
{
|
||||
define('PAGEBUILDERCK_MEDIA_URI', JUri::root(true) . '/media/com_pagebuilderck');
|
||||
}
|
||||
|
||||
require_once(PAGEBUILDERCK_PATH . '/helpers/defines.js.php');
|
||||
|
||||
$doc = JFactory::getDocument();
|
||||
$editor = JFactory::getConfig()->get('pagebuilderck_replaced_editor', '') ? JFactory::getConfig()->get('pagebuilderck_replaced_editor') : JFactory::getConfig()->get('editor');
|
||||
$editor = $editor == 'jce' ? 'jce' : 'tinymce';
|
||||
|
||||
$input = CKFof::getInput();
|
||||
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/pagebuilderck.css?ver=<?php echo PAGEBUILDERCK_VERSION ?>" type="text/css" />
|
||||
<link rel="stylesheet" href="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/ckframework.css" type="text/css" />
|
||||
<?php // needs also to load the frontend styles to make the same visual as on frontend ?>
|
||||
<link rel="stylesheet" href="<?php echo JUri::root(true) ?>/components/com_pagebuilderck/assets/pagebuilderck.css?ver=<?php echo PAGEBUILDERCK_VERSION ?>" type="text/css" />
|
||||
<link rel="stylesheet" href="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/colpick.css" type="text/css" />
|
||||
<link rel="stylesheet" href="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/ckbox.css" type="text/css" />
|
||||
<link rel="stylesheet" href="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/codemirrorck.css" type="text/css" />
|
||||
<?php
|
||||
if (PAGEBUILDERCK_LOADEDITORCSS === '1') {
|
||||
$defaultTemplate = PagebuilderckHelper::getDefaultTemplate();
|
||||
if (file_exists(JPATH_ROOT . '/templates/<?php echo $defaultTemplate ?>/css/editor.css')) {
|
||||
?>
|
||||
<link rel="stylesheet" href="<?php echo JUri::root(true) ?>/templates/<?php echo $defaultTemplate ?>/css/editor.css" type="text/css" />
|
||||
<?php
|
||||
}
|
||||
|
||||
}
|
||||
// call google fonts
|
||||
$googlefontsFromTemplate = PagebuilderckHelper::loadTemplateGooglefonts();
|
||||
$fonts = PagebuilderckHelper::getFonts();
|
||||
if (! empty($googlefontsFromTemplate) && ! empty($googlefontsFromTemplate)) {
|
||||
?><link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin><?php
|
||||
}
|
||||
if (! empty($googlefontsFromTemplate)) {
|
||||
foreach ($googlefontsFromTemplate as $i => $gfont) {
|
||||
PagebuilderckHelper::loadTemplateGooglefontFile($gfont);
|
||||
/*
|
||||
?><link href="https://fonts.googleapis.com/css2?family=<?php echo $gfont ?>&display=swap" rel="stylesheet"><?php
|
||||
*/
|
||||
}
|
||||
}
|
||||
if (! empty($fonts)) {
|
||||
foreach ($fonts as $i => $font) {
|
||||
if ($font->local === 1) {
|
||||
$url = PagebuilderckHelper::getFontPath($font->name);
|
||||
?> <link href="<?php echo $url ?>" rel="stylesheet"><?php
|
||||
} else { ?>
|
||||
<link href="<?php echo $font->url ?>" rel="stylesheet"><?php
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
var URIROOT = PAGEBUILDERCK.URIROOT; // BC for old plugins
|
||||
var URIBASE = PAGEBUILDERCK.URIBASE; // BC for old plugins
|
||||
var CLIPBOARDCK = '';
|
||||
var CLIPBOARDCOLORCK = '';
|
||||
var BLOCCKSTYLESBACKUP = '';
|
||||
var FAVORITELOCKED = '';
|
||||
var JoomlaCK = {};
|
||||
var PAGEBUILDERCK_MEDIA_URI = '<?php echo PAGEBUILDERCK_MEDIA_URI ?>';
|
||||
var PAGEBUILDERCK_ADMIN_URL = '<?php echo PAGEBUILDERCK_ADMIN_URL ?>';
|
||||
//var PAGEBUILDERCK_TOKEN = cktoken = '<?php echo JFactory::getSession()->getFormToken() ?>=1';
|
||||
var PAGEBUILDERCK_EDITOR = '<?php echo $editor ?>';
|
||||
PAGEBUILDERCK.ISCONTENTTYPE = '<?php echo $input->get('iscontenttype', 0, 'int') ?>';
|
||||
</script>
|
||||
<?php
|
||||
// modal view : strange that Joomla 4 do not want to load the script at the end in modal view
|
||||
if ((version_compare(JVERSION,'4') <= 1) || $input->get('layout', '') === 'modal' || (CKFof::isSite() && $input->get('layout', '') === 'edit')) { ?>
|
||||
<?php if (version_compare(JVERSION,'4') < 1) JHtml::_('behavior.core'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/jqueryck.min.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/jquery-uick-custom.min.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/ckbox.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/codemirrorck.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/php.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/javascript.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/ckframework.js'); ?>
|
||||
<?php CKFof::addScript(JUri::root(true) . '/components/com_pagebuilderck/assets/jquery-uick.min.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/ckbrowse.js?ver=' . PAGEBUILDERCK_VERSION); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/colpick.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/pagebuilderck.js?ver=' . PAGEBUILDERCK_VERSION); ?>
|
||||
<style>
|
||||
body > .container-fluid {
|
||||
padding-left: 35px;
|
||||
}
|
||||
</style>
|
||||
<?php
|
||||
// normal view
|
||||
} else { ?>
|
||||
<?php CKFof::addScript(JUri::root(true) . '/components/com_pagebuilderck/assets/jquery-uick.min.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/ckbrowse.js?ver=' . PAGEBUILDERCK_VERSION); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/colpick.js'); ?>
|
||||
<?php CKFof::addScript(PAGEBUILDERCK_MEDIA_URI . '/assets/pagebuilderck.js?ver=' . PAGEBUILDERCK_VERSION); ?>
|
||||
<?php JHtml::_('jquery.framework'); ?>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/jqueryck.min.js" type="text/javascript"></script>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/jquery-uick-custom.min.js" type="text/javascript"></script>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/ckbox.js" type="text/javascript"></script>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/codemirrorck.js" type="text/javascript"></script>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/php.js" type="text/javascript"></script>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/javascript.js" type="text/javascript"></script>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/css.js" type="text/javascript"></script>
|
||||
<script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/ckframework.js" type="text/javascript"></script>
|
||||
<?php } ?>
|
||||
|
||||
<?php
|
||||
// load the CK Framework
|
||||
//require_once JPATH_ADMINISTRATOR . '/components/com_pagebuilderck/helpers/ckframework.php';
|
||||
//\Pagebuilderck\CKFramework::loadInline();
|
||||
|
||||
switch ($editor) {
|
||||
case 'jce':
|
||||
?><script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/editors/jce.js" type="text/javascript"></script><?php
|
||||
break;
|
||||
case 'tinymce':
|
||||
default:
|
||||
if (version_compare(JVERSION, '4') >= 0) { // check if we are in Joomla 3.7
|
||||
?><script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/editors/tinymce3.js" type="text/javascript"></script><?php
|
||||
} else if (version_compare(JVERSION, '3.7') >= 0) { // check if we are in Joomla 3.7
|
||||
?><script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/editors/tinymce2.js" type="text/javascript"></script><?php
|
||||
} else { // we are still in an old version
|
||||
?><script src="<?php echo PAGEBUILDERCK_MEDIA_URI ?>/assets/editors/tinymce1.js" type="text/javascript"></script><?php
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
JText::script('CK_CONFIRM_DELETE');
|
||||
JText::script('CK_FAILED_SET_TYPE');
|
||||
JText::script('CK_FAILED_SAVE_ITEM_ERRORMENUTYPE');
|
||||
JText::script('CK_ALIAS_EXISTS_CHOOSE_ANOTHER');
|
||||
JText::script('CK_FAILED_SAVE_ITEM_ERROR500');
|
||||
JText::script('CK_FAILED_SAVE_ITEM');
|
||||
JText::script('CK_FAILED_TRASH_ITEM');
|
||||
JText::script('CK_FAILED_CREATE_ITEM');
|
||||
JText::script('CK_UNABLE_UNPUBLISH_HOME');
|
||||
JText::script('CK_TITLE_NOT_UPDATED');
|
||||
JText::script('CK_LEVEL_NOT_UPDATED');
|
||||
JText::script('CK_SAVE_LEVEL_FAILED');
|
||||
JText::script('CK_SAVE_ORDER_FAILED');
|
||||
JText::script('CK_CHECKIN_NOT_UPDATED');
|
||||
JText::script('CK_CHECKIN_FAILED');
|
||||
JText::script('CK_PARAM_NOT_UPDATED');
|
||||
JText::script('CK_PARAM_UPDATE_FAILED');
|
||||
JText::script('CK_FIRST_CREATE_ROW');
|
||||
JText::script('CK_EDIT');
|
||||
JText::script('CK_ICON');
|
||||
JText::script('CK_MODULE');
|
||||
JText::script('CK_GOOGLE_FONT');
|
||||
JText::script('CK_FULLSCREEN');
|
||||
JText::script('CK_RESTORE');
|
||||
JText::script('CK_REMOVE_BLOCK');
|
||||
JText::script('CK_MOVE_BLOCK');
|
||||
JText::script('CK_EDIT_STYLES');
|
||||
JText::script('CK_DECREASE_WIDTH');
|
||||
JText::script('CK_INCREASE_WIDTH');
|
||||
JText::script('CK_ADD_BLOCK');
|
||||
JText::script('CK_REMOVE_ROW');
|
||||
JText::script('CK_EDIT_COLUMNS');
|
||||
JText::script('CK_MOVE_ROW');
|
||||
JText::script('CK_ADD_NEW_ROW');
|
||||
JText::script('CK_REMOVE_ITEM');
|
||||
JText::script('CK_REMOVE_ITEM');
|
||||
JText::script('CK_MOVE_ITEM');
|
||||
JText::script('CK_DUPLICATE_ITEM');
|
||||
JText::script('CK_DUPLICATE_ROW');
|
||||
JText::script('CK_EDIT_ITEM');
|
||||
JText::script('CK_ADD_COLUMN');
|
||||
JText::script('CK_DELETE');
|
||||
JText::script('CK_SAVE_CLOSE');
|
||||
JText::script('CK_DESIGN_SUGGESTIONS');
|
||||
JText::script('CK_MORE_MENU_ELEMENTS');
|
||||
JText::script('CK_FULLWIDTH');
|
||||
JText::script('CK_DUPLICATE_COLUMN');
|
||||
JText::script('CK_ENTER_CLASSNAMES');
|
||||
JText::script('CHECK_IDS_ALERT_PROBLEM');
|
||||
JText::script('CHECK_IDS_ALERT_OK');
|
||||
JText::script('CK_ENTER_UNIQUE_ID');
|
||||
JText::script('CK_INVALID_ID');
|
||||
JText::script('CK_ENTER_VALID_ID');
|
||||
JText::script('CK_CONFIRM_BEFORE_CLOSE_EDITION_POPUP');
|
||||
JText::script('CK_SUGGESTIONS');
|
||||
JText::script('CK_RESPONSIVE_SETTINGS_ALIGNED');
|
||||
JText::script('CK_RESPONSIVE_SETTINGS_STACKED');
|
||||
JText::script('CK_RESPONSIVE_SETTINGS_HIDDEN');
|
||||
JText::script('CK_SAVE');
|
||||
JText::script('CK_WRAPPER_IN_WRAPPER_NOT_ALLOWED');
|
||||
JText::script('CK_DUPLICATE_WRAPPER');
|
||||
JText::script('CK_MOVE_WRAPPER');
|
||||
JText::script('CK_REMOVE_WRAPPER');
|
||||
JText::script('CK_ADD_NEW_PAGEBUILDER_MODULE');
|
||||
JText::script('CK_ADD');
|
||||
JText::script('CK_DRAG_DROP_PAGE');
|
||||
JText::script('CK_PAGE');
|
||||
JText::script('CK_ACCESS_RIGHTS');
|
||||
JText::script('CK_CLIPBOARDEMPTY');
|
||||
JText::script('CK_COPYFROMCLIPBOARD');
|
||||
JText::script('CK_FIRST_CLEAR_VALUE');
|
||||
JText::script('CK_CLICK_TO_EDIT_CONTENT');
|
||||
JText::script('CK_CLEAN');
|
||||
JText::script('CK_SELECT');
|
||||
JText::script('CK_CONFIRM_CLEAR_STYLES');
|
||||
JText::script('CK_VALIGN_DEFAULT');
|
||||
JText::script('CK_VALIGN_TOP');
|
||||
JText::script('CK_VALIGN_CENTER');
|
||||
JText::script('CK_VALIGN_BOTTOM');
|
||||
JText::script('CK_FONT_ICON');
|
||||
JText::script('CK_SVG_ICON');
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
function ckKeepAlive() {
|
||||
$ck.ajax({type: "POST", url: "index.php"});
|
||||
}
|
||||
|
||||
<?php if (! PagebuilderckHelper::getParams()) { ?>
|
||||
function ckShowFavoritePopup() {
|
||||
CKBox.open({handler:'inline',content: 'pagebuilderckparamsmessage', fullscreen: false, size: {x: '600px', y: '150px'}});
|
||||
}
|
||||
function ckShowLibraryPopup() {
|
||||
CKBox.open({handler:'inline',content: 'pagebuilderckparamsmessage', fullscreen: false, size: {x: '600px', y: '150px'}});
|
||||
}
|
||||
<?php } ?>
|
||||
|
||||
$ck(document).ready(function()
|
||||
{
|
||||
CKApi.Tooltip('.cktip');
|
||||
window.setInterval("ckKeepAlive()", 600000);
|
||||
});
|
||||
</script>
|
||||
<style>
|
||||
.tox.tox-silver-sink.tox-tinymce-aux {z-index: 99999}
|
||||
#ckeditor_ArticleModal {z-index: 99999};
|
||||
|
||||
</style>
|
||||
@@ -0,0 +1 @@
|
||||
<html><body bgcolor="#FFFFFF"></body></html>
|
||||
@@ -0,0 +1,184 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
$user = JFactory::getUser();
|
||||
$app = JFactory::getApplication();
|
||||
$input = $app->input;
|
||||
|
||||
$assoc = isset($app->item_associations) ? $app->item_associations : 0;
|
||||
$canEdit = $user->authorise('core.edit', 'com_pagebuilderck');
|
||||
$appendUrl = $this->input->get('layout', '', 'string') == 'modal' ? '&layout=modal&tmpl=component' : '&layout=edit';
|
||||
// get global component params
|
||||
$params = JComponentHelper::getParams('com_pagebuilderck');
|
||||
// get item params
|
||||
if (! is_object($this->item->params)) $this->item->params = new JRegistry($this->item->params);
|
||||
// merge params
|
||||
$params->merge($this->item->params);
|
||||
$params->merge($this->item->params);
|
||||
$conf = JFactory::getConfig();
|
||||
?>
|
||||
<div style="display:none;">
|
||||
<form>
|
||||
<?php
|
||||
// Load the editor Tinymce or JCE
|
||||
$editor = $conf->get('editor') == 'jce' ? 'jce' : 'tinymce';
|
||||
$editor = JEditor::getInstance($editor);
|
||||
echo $editor->display('ckeditor', $html = '', $width = '', $height = '200px', $col='', $row='', $buttons = true, $id = 'ckeditor');
|
||||
?>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div id="mainck">
|
||||
|
||||
<div id="maincktabcontent">
|
||||
|
||||
<?php if ($canEdit) { ?>
|
||||
<form action="<?php echo JRoute::_('index.php?option=com_pagebuilderck&view=page' . $appendUrl . '&id=' . $this->item->id);?>" method="post" name="adminForm" id="adminForm" enctype="multipart/form-data" class="form-validate">
|
||||
<?php if (\Pagebuilderck\CKFof::isSite() && $app->input->get('layout') != 'modal') { ?>
|
||||
<div class="btn-toolbar">
|
||||
<div class="btn-group">
|
||||
<button type="button" class="btn btn-primary" onclick="Joomla.submitbutton('page.apply')">
|
||||
<span class="icon-apply"></span> <?php echo JText::_('JSAVE') ?>
|
||||
</button>
|
||||
</div>
|
||||
<div class="btn-group">
|
||||
<button type="button" class="btn btn-primary" onclick="Joomla.submitbutton('page.save')">
|
||||
<span class="icon-ok"></span> <?php echo JText::_('CK_SAVE_CLOSE') ?>
|
||||
</button>
|
||||
</div>
|
||||
<div class="btn-group">
|
||||
<button type="button" class="btn" onclick="Joomla.submitbutton('page.cancel')">
|
||||
<span class="icon-cancel"></span> <?php echo JText::_('JCANCEL') ?>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<div class="mainmenulink menulink current" tab="tab_interface"><?php echo JText::_('CK_EDITION'); ?></div>
|
||||
<div class="mainmenulink menulink" tab="tab_options"><?php echo JText::_('CK_OPTIONS'); ?></div>
|
||||
<div class="clr"></div>
|
||||
|
||||
<div class="form-inline form-inline-header clearfix ckinterface">
|
||||
<div>
|
||||
<label class="required" for="title" id="title-lbl">
|
||||
<?php echo JText::_('COM_PAGEBUILDERCK_TITLE'); ?>
|
||||
<span class="star"> *</span>
|
||||
</label>
|
||||
<input type="text" aria-required="true" required="required" size="40" class="form-control input-xlarge input-large-text required" value="<?php echo $this->item->title ?>" id="title" name="title">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="maintab menustyles ckproperty" id="tab_options">
|
||||
<?php
|
||||
// loads the options layout
|
||||
include_once(PAGEBUILDERCK_PATH . '/views/page/tmpl/options.php');
|
||||
?>
|
||||
</div>
|
||||
|
||||
<input type="hidden" name="htmlcode" id="htmlcode" value="" />
|
||||
<input type="hidden" name="params" id="params" value="" />
|
||||
<input type="hidden" name="option" value="com_pagebuilderck" />
|
||||
<input type="hidden" name="id" value="<?php echo $this->item->id; ?>" />
|
||||
<input type="hidden" name="task" value="" />
|
||||
<input type="hidden" name="controller" value="com_pagebuilderck" />
|
||||
<input type="hidden" name="return" value="<?php echo $this->input->getCmd('return'); ?>" />
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</form>
|
||||
<div> </div>
|
||||
<div class="maintab menustyles current ckproperty" id="tab_interface">
|
||||
<div id="workspaceparentck">
|
||||
<?php
|
||||
// loads the menu
|
||||
include_once(PAGEBUILDERCK_PATH . '/views/page/tmpl/contextmenu.php');
|
||||
include_once(PAGEBUILDERCK_PATH . '/views/page/tmpl/menu.php');
|
||||
include_once(PAGEBUILDERCK_PATH . '/views/page/tmpl/toolbar.php');
|
||||
?>
|
||||
<div id="workspaceck" class="pagebuilderck workspaceck<?php echo (\Pagebuilderck\CKFof::isSite() ? ' pagebuilderckfrontend' : '') ?><?php echo ($this->input->get('iscontenttype', 0, 'int') === 1 ? ' ckiscontenttype' : '') ?>" >
|
||||
<?php
|
||||
if ($this->item->htmlcode) {
|
||||
echo $this->item->htmlcode;
|
||||
} else { ?>
|
||||
<div class="googlefontscall"></div>
|
||||
<?php }
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php // load the modal for the restoration ?>
|
||||
<div id="pagebuilderckRestoreModalck" class="pagebuilderckRestoreModalck pagebuilderckModalck" style="display:none;">
|
||||
<h3><?php echo JText::_('CK_RESTORE') ?></h3>
|
||||
<div class="ckinterface">
|
||||
<?php
|
||||
if ($this->item->id) {
|
||||
$path = JPATH_ROOT . '/administrator/components/com_pagebuilderck/backup/' . $this->item->id . '_bak';
|
||||
if (JFolder::exists($path)) {
|
||||
$files = JFolder::files($path, '.pbck', false, false);
|
||||
if (count($files)) {
|
||||
natsort($files);
|
||||
$i = 0;
|
||||
foreach ($files as $file) {
|
||||
if (stristr($file, 'locked_')) {
|
||||
$backupdate = str_replace('locked_' . $this->item->id . '_', '', JFile::stripExt($file));
|
||||
$isLocked = true;
|
||||
} else {
|
||||
$backupdate = str_replace('backup_' . $this->item->id . '_', '', JFile::stripExt($file));
|
||||
$isLocked = false;
|
||||
}
|
||||
$date = DateTime::createFromFormat('d-m-Y-G-i-s', $backupdate);
|
||||
$lockedIcon = $isLocked ? '<span class="ck-icon-lock"></span>' : '<span class="ck-icon-lock-open"></span>';
|
||||
|
||||
echo '<div class="restoreline restoreline' . $i . ' clearfix">
|
||||
<span class="span6">
|
||||
<span class="cklabel cklabel-info">' . $date->format('d-M-Y H:i:s') . '</span>
|
||||
</span>
|
||||
<span class="span6">
|
||||
<span onclick="ckToggleLockedBackup(' . $this->item->id . ',\'' . $backupdate . '\', ' . $i . ')" data-locked="' . ($isLocked ? ' 1' : '0') . '" class="ckbutton locked' . ($isLocked ? ' active' : '') . '" style="margin:0 3px;display:inline-block;">' . $lockedIcon . '</span>
|
||||
<a class="ckbutton" href="javascript:void(0)" onclick="ckDoRestoration(' . $this->item->id . ', \'' . $backupdate . '\', ' . $i . ')">
|
||||
' . JText::_('CK_DO_RESTORATION') . '
|
||||
</a>
|
||||
<span class="processing" style="width:16px;margin:0 3px;display:inline-block;"> </span>
|
||||
</span>
|
||||
</div>';
|
||||
$i++;
|
||||
}
|
||||
} else {
|
||||
echo '<div class="ckalert">' . JText::_('CK_NO_RESTORE_FILE_FOUND') . '</div>';
|
||||
}
|
||||
} else {
|
||||
echo '<div class="ckalert">' . JText::_('CK_NO_RESTORE_FILE_FOUND') . '</div>';
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php } else {
|
||||
if (!$canEdit) echo JText::_('COM_PAGEBUILDERCK_NORIGHTS_TO_EDIT');
|
||||
} ?>
|
||||
</div> <?php // fin tab_interface ?>
|
||||
|
||||
</div><?php // fin maincktabcontent ?>
|
||||
</div>
|
||||
<script>
|
||||
$ck('#maincktabcontent div.maintab:not(.current)').hide();
|
||||
$ck('.mainmenulink', $ck('#mainck')).each(function(i, tab) {
|
||||
$ck(tab).click(function() {
|
||||
if ($ck('#popup_favoriteck').length) {
|
||||
ckCloseFavoritePopup(true);
|
||||
}
|
||||
$ck('#maincktabcontent div.maintab').hide();
|
||||
$ck('.mainmenulink', $ck('#mainck')).removeClass('current');
|
||||
if ($ck('#' + $ck(tab).attr('tab')).length)
|
||||
$ck('#' + $ck(tab).attr('tab')).show();
|
||||
$ck(this).addClass('current');
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
require(JPATH_ADMINISTRATOR . '/components/com_pagebuilderck/views/page/tmpl/submitform.php');
|
||||
@@ -0,0 +1,752 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
jimport('joomla.filesystem.file');
|
||||
jimport('joomla.filesystem.folder');
|
||||
$app = JFactory::getApplication();
|
||||
$input = $app->input;
|
||||
|
||||
// load the custom plugins
|
||||
JPluginHelper::importPlugin( 'pagebuilderck' );
|
||||
//$dispatcher = JEventDispatcher::getInstance();
|
||||
?>
|
||||
<style type="text/css">
|
||||
<?php if ($input->get('view', '', 'string') === 'style') { ?>
|
||||
.menuckpanel[data-target="pages"],
|
||||
.menuckpanel[data-target="library"] {
|
||||
display: none !important;
|
||||
}
|
||||
<?php } ?>
|
||||
<?php if ($input->get('iscontenttype', 0, 'int') !== 1) { ?>
|
||||
body {
|
||||
margin-left: 310px;
|
||||
}
|
||||
<?php } ?>
|
||||
|
||||
body.hidepanel {
|
||||
margin-left: 50px;
|
||||
}
|
||||
|
||||
body.hidepanel .menuck {
|
||||
width: 50px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
body.hidepanel #togglepanel ~ *,
|
||||
body.hidepanel .menuckpanel,
|
||||
body.hidepanel .menuckpanelfake {
|
||||
display: none;
|
||||
}
|
||||
|
||||
body.hidepanel #togglepanel {
|
||||
width: 50px;
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
body.tck-edition-body {
|
||||
margin-left: 310px;
|
||||
width: calc(100% - 310px);
|
||||
}
|
||||
|
||||
.menuck {
|
||||
background-color: #f5f5f5;
|
||||
border: none;
|
||||
display: block;
|
||||
left: 0;
|
||||
padding: 0 0 10px 0px;
|
||||
width: 310px;
|
||||
box-sizing: border-box;
|
||||
z-index: 1039;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
overflow-y: scroll;
|
||||
overflow-x: hidden;
|
||||
margin: 0;
|
||||
font-family: Segoe UI, arial;
|
||||
}
|
||||
|
||||
.menuck .menuckinfos {
|
||||
margin: 5px 0;
|
||||
padding: 5px;
|
||||
font-size: 12px;
|
||||
line-height: 12px;
|
||||
}
|
||||
|
||||
.menuck .menuitemck:hover {
|
||||
border: 1px solid #ddd;
|
||||
}
|
||||
|
||||
.menuck img {
|
||||
margin: 1px;
|
||||
}
|
||||
|
||||
.menuck .menuitemck, .workspaceck .menuitemck {
|
||||
background: #fff none repeat scroll 0 0;
|
||||
border: 1px solid #f2f2f2;
|
||||
float: left;
|
||||
height: 40px;
|
||||
margin: 5px 0 0 5px;
|
||||
padding: 5px;
|
||||
width: 47%;
|
||||
max-width: 125px;
|
||||
cursor: grab;
|
||||
cursor: -webkit-grab;
|
||||
box-sizing: border-box;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.menuck .menuitemck.grabbing, .workspaceck .menuitemck.grabbing {
|
||||
cursor: grabbing;
|
||||
cursor: -webkit-grabbing;
|
||||
}
|
||||
|
||||
.menuck .menuitemck .menuitemck_title, .workspaceck .menuitemck .menuitemck_title {
|
||||
font-size: 12px;
|
||||
line-height: 15px;
|
||||
align-self: center;
|
||||
}
|
||||
|
||||
.menuck .menuitemck .menuitemck_desc, .workspaceck .menuitemck .menuitemck_desc {
|
||||
color: #1a1a1a;
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.menuck .menuitemck > div, .workspaceck .menuitemck > div {
|
||||
float: right;
|
||||
width: calc(100% - 28px);
|
||||
height: 28px;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.menuck .menuitemck img, .workspaceck .menuitemck img {
|
||||
float: left;
|
||||
margin: 5px 0 0 2px;
|
||||
width: 20px;
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.menuitemck_group {
|
||||
clear: both;
|
||||
padding: 2px 5px;
|
||||
text-transform: capitalize;
|
||||
border-bottom: 2px solid #2E5A84;
|
||||
color: #2E5A84;
|
||||
margin: 5px 5px 0;
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.menuck .headerck {
|
||||
cursor: pointer;
|
||||
padding: 0 0 0 5px;
|
||||
background: none;
|
||||
font-size: 18px;
|
||||
min-height: 40px;
|
||||
|
||||
}
|
||||
|
||||
.menuck .ckinterface {
|
||||
background: none;
|
||||
}
|
||||
|
||||
#workspaceparentck.collapsedck .menuck {
|
||||
width: 75px;
|
||||
}
|
||||
|
||||
#workspaceparentck.collapsedck .menuck .headercktext,
|
||||
#workspaceparentck.collapsedck .menuck .menuckinfos,
|
||||
#workspaceparentck.collapsedck .menuck .menuitemck > div,
|
||||
#workspaceparentck.collapsedck .menuck .menuitemck_title,
|
||||
#workspaceparentck.collapsedck .menuck .menuitemck_desc {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#workspaceparentck.collapsedck .menuck .menuitemck {
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
margin: 5px 2px;
|
||||
}
|
||||
|
||||
/*#workspaceparentck:not(.collapsedck) #workspaceck {
|
||||
margin-left: 235px;
|
||||
}
|
||||
|
||||
#module-form #workspaceparentck:not(.collapsedck) #workspaceck {
|
||||
margin-left: 260px;
|
||||
}*/
|
||||
|
||||
.menuck .headercktext {
|
||||
display: inline-block;
|
||||
width: 145px;
|
||||
line-height: 32px;
|
||||
vertical-align: top;
|
||||
padding-left: 5px;
|
||||
margin-top: 5px;
|
||||
font-weight: 600;
|
||||
color: #2E5A84;
|
||||
}
|
||||
|
||||
.menuck .menuckinner {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.menuck > .inner {
|
||||
/*position: relative;*/
|
||||
max-height: 100%;
|
||||
height: calc(100vh - 50px);
|
||||
overflow-y: auto;
|
||||
margin-left: 50px;
|
||||
}
|
||||
|
||||
.menuck > .inner:not(.ckelementsedition) {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.menuck .ckcolumnsedition {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.menuck .headerckicon {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
float: right;
|
||||
display: inline-block;
|
||||
box-sizing: border-box;
|
||||
line-height: 32px;
|
||||
padding: 0;
|
||||
background: none;
|
||||
color: #000;
|
||||
font-size: 1.3em;
|
||||
border: none;
|
||||
text-align: center;
|
||||
cursor: pointer;
|
||||
font-weight: normal;
|
||||
border-radius: 0;
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
.menuck .headerckicon:hover {
|
||||
color: #000;
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.collapsedck .menuck .headerckicon {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
.menuck .headerckicon.cksave,
|
||||
.menuck .headerckicon.ckclean {
|
||||
font-size: 13px;
|
||||
line-height: 35px;
|
||||
}
|
||||
|
||||
.menuck input {
|
||||
width: auto;
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
.menuck .ckresponsivebutton {
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 4px;
|
||||
box-shadow: none;
|
||||
width: 205px;
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
.menuck .ckresponsivebutton.active {
|
||||
border-color: #faa732;
|
||||
}
|
||||
|
||||
.menuck .ckbutton-group .ckresponsivebutton:not(#ckresponsive5button) {
|
||||
border-radius: 4px 0 0 4px;
|
||||
height: 30px;
|
||||
}
|
||||
|
||||
.menuck .ckbutton-group .ckresponsivebutton ~ .ckresponsivebutton:not(#ckresponsive5button) {
|
||||
border-radius: 0 4px 4px 0;
|
||||
}
|
||||
|
||||
#popup_editionck .menulink {
|
||||
background: #fff;
|
||||
border: none;
|
||||
border-bottom: 1px solid #ddd;
|
||||
padding: 10px 10px 10px 14px;
|
||||
border-radius: 0px;
|
||||
border-left: 4px solid #fff;
|
||||
font-weight: 600;
|
||||
font-size: 16px;
|
||||
color: #555;
|
||||
font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif;
|
||||
}
|
||||
|
||||
#popup_editionck .menulink:hover,
|
||||
#popup_editionck .menulink.open{
|
||||
color: #0073aa;
|
||||
background: #f8f8f8;
|
||||
border-bottom: 1px solid #0073aa;
|
||||
}
|
||||
|
||||
/* Fix for Safari */
|
||||
.ckpopup, .menuck {
|
||||
overflow: visible !important;
|
||||
}
|
||||
|
||||
.menuckpanels {
|
||||
width: 50px;
|
||||
background: #1C3D5C;
|
||||
height: calc(100vh - 40px);
|
||||
float: left;
|
||||
}
|
||||
|
||||
.menuckpanelfake img,
|
||||
.menuckpanel img {
|
||||
margin: 8px;
|
||||
}
|
||||
|
||||
.menuckpanel svg {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
fill: #fff;
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
||||
.menuckpanel.active svg {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.menuckpanelfake,
|
||||
.menuckpanel {
|
||||
color: #ddd;
|
||||
text-align: center;
|
||||
padding: 12px 0;
|
||||
}
|
||||
|
||||
.menuckpanelfake .fa,
|
||||
.menuckpanel .fa {
|
||||
font-size: 24px;
|
||||
}
|
||||
|
||||
.menuckpanelfake.active, .menuckpanelfake:hover,
|
||||
.menuckpanel.active, .menuckpanel:hover {
|
||||
background: #2E5A84;
|
||||
color: #fff;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.menuckbootomtoolbar {
|
||||
height: 40px;
|
||||
background: #2E5A84;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
left: 0;
|
||||
text-align: center;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
padding-left: 40px;
|
||||
}
|
||||
|
||||
.menuckbootomtoolbar span.menuckbootomtoolbar-button {
|
||||
height: 40px;
|
||||
width: 40px;
|
||||
border-radius: 0;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
line-height: 40px;
|
||||
color: #fff;
|
||||
padding: 0 10px;
|
||||
opacity: 0.7;
|
||||
display: inline-block;
|
||||
cursor: pointer;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.menuckbootomtoolbar span.menuckbootomtoolbar-button:hover, .menuckbootomtoolbar span.menuckbootomtoolbar-button.active {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.menuckbootomtoolbar a:before {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.ckresponsivebutton {
|
||||
width: 170px;
|
||||
}
|
||||
|
||||
.ckmyelements.headerck {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.ckaddonsdisplaytype {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#cklibraryiframe {
|
||||
padding: 10px;
|
||||
}
|
||||
<?php
|
||||
$displaytype = $app->getUserState('pagebuilderck.addons.displaytype', 'list');
|
||||
echo '#ckaddonsdisplaytype' . $displaytype . ' { display: block; }';
|
||||
?>
|
||||
</style>
|
||||
<?php
|
||||
// get global component params
|
||||
$componentParams = JComponentHelper::getParams('com_pagebuilderck');
|
||||
$view = $input->get('view', 'page');
|
||||
?>
|
||||
<?php
|
||||
if ($input->get('iscontenttype', 0, 'int') !== 1) { ?>
|
||||
<div id="menuck" class="menuck clearfix ckinterface">
|
||||
<div class="menuckpanels">
|
||||
<div class="menuckpanel cktip active" data-target="addons" title="<?php echo JText::_('CK_ADDONS') ?>" data-placement="right">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1728 1098q0 81-44.5 135t-123.5 54q-41 0-77.5-17.5t-59-38-56.5-38-71-17.5q-110 0-110 124 0 39 16 115t15 115v5q-22 0-33 1-34 3-97.5 11.5t-115.5 13.5-98 5q-61 0-103-26.5t-42-83.5q0-37 17.5-71t38-56.5 38-59 17.5-77.5q0-79-54-123.5t-135-44.5q-84 0-143 45.5t-59 127.5q0 43 15 83t33.5 64.5 33.5 53 15 50.5q0 45-46 89-37 35-117 35-95 0-245-24-9-2-27.5-4t-27.5-4l-13-2q-1 0-3-1-2 0-2-1v-1024q2 1 17.5 3.5t34 5 21.5 3.5q150 24 245 24 80 0 117-35 46-44 46-89 0-22-15-50.5t-33.5-53-33.5-64.5-15-83q0-82 59-127.5t144-45.5q80 0 134 44.5t54 123.5q0 41-17.5 77.5t-38 59-38 56.5-17.5 71q0 57 42 83.5t103 26.5q64 0 180-15t163-17v2q-1 2-3.5 17.5t-5 34-3.5 21.5q-24 150-24 245 0 80 35 117 44 46 89 46 22 0 50.5-15t53-33.5 64.5-33.5 83-15q82 0 127.5 59t45.5 143z"/></svg>
|
||||
</div>
|
||||
<?php if ($pagebuilderckParams->get('enablepanel_pages', '1', 'int') !== '0') { ?>
|
||||
<div class="menuckpanel cktip" data-target="pages" title="<?php echo JText::_('CK_LOAD_PAGE') ?>" data-placement="right">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1596 380q28 28 48 76t20 88v1152q0 40-28 68t-68 28h-1344q-40 0-68-28t-28-68v-1600q0-40 28-68t68-28h896q40 0 88 20t76 48zm-444-244v376h376q-10-29-22-41l-313-313q-12-12-41-22zm384 1528v-1024h-416q-40 0-68-28t-28-68v-416h-768v1536h1280zm-1024-864q0-14 9-23t23-9h704q14 0 23 9t9 23v64q0 14-9 23t-23 9h-704q-14 0-23-9t-9-23v-64zm736 224q14 0 23 9t9 23v64q0 14-9 23t-23 9h-704q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h704zm0 256q14 0 23 9t9 23v64q0 14-9 23t-23 9h-704q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h704z"/></svg>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php if ($pagebuilderckParams->get('enablepanel_styles', '1', 'int') !== '0') { ?>
|
||||
<?php if ($view !== 'element') { ?>
|
||||
<div class="menuckpanel cktip" data-target="styles" title="<?php echo JText::_('CK_LOAD_STYLE') ?>" data-placement="right">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1615 0q70 0 122.5 46.5t52.5 116.5q0 63-45 151-332 629-465 752-97 91-218 91-126 0-216.5-92.5t-90.5-219.5q0-128 92-212l638-579q59-54 130-54zm-909 1034q39 76 106.5 130t150.5 76l1 71q4 213-129.5 347t-348.5 134q-123 0-218-46.5t-152.5-127.5-86.5-183-29-220q7 5 41 30t62 44.5 59 36.5 46 17q41 0 55-37 25-66 57.5-112.5t69.5-76 88-47.5 103-25.5 125-10.5z"/></svg>
|
||||
</div><?php } ?>
|
||||
<div class="menuckpanel cktip" data-target="library" title="<?php echo JText::_('CK_LOAD_MODEL') ?>" data-placement="right">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M512 1248v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm0-512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm-640-1024v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm-640-1024v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm640 512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68zm0-512v192q0 40-28 68t-68 28h-320q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h320q40 0 68 28t28 68z"/></svg>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php if ($input->get('tckedition', 0, 'int') == 0) { ?>
|
||||
<?php if ($pagebuilderckParams->get('enablepanel_responsive', '1', 'int') !== '0') { ?>
|
||||
<div id="ckresponsivesettingsbutton" data-target="responsive" class="menuckpanel cktip" title="<?php echo JText::_('CK_RESPONSIVE_SETTINGS') ?>" data-placement="right">
|
||||
<svg style="width:36px;height:36px;" width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M976 1408q0-33-23.5-56.5t-56.5-23.5-56.5 23.5-23.5 56.5 23.5 56.5 56.5 23.5 56.5-23.5 23.5-56.5zm208-160v-704q0-13-9.5-22.5t-22.5-9.5h-512q-13 0-22.5 9.5t-9.5 22.5v704q0 13 9.5 22.5t22.5 9.5h512q13 0 22.5-9.5t9.5-22.5zm-192-848q0-16-16-16h-160q-16 0-16 16t16 16h160q16 0 16-16zm288-16v1024q0 52-38 90t-90 38h-512q-52 0-90-38t-38-90v-1024q0-52 38-90t90-38h512q52 0 90 38t38 90z"/></svg> </div>
|
||||
<?php } ?>
|
||||
<?php if ($pagebuilderckParams->get('enablepanel_customcss', '1', 'int') !== '0') { ?>
|
||||
<div id="ckcustomcsssettingsbutton" data-target="customcss" class="menuckpanelfake cktip" title="<?php echo JText::_('CK_CUSTOMCSS') ?>" data-placement="right">
|
||||
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<div class="inner clearfix ckelementsedition menuckpaneltarget" data-target="addons">
|
||||
<div class="headerck">
|
||||
<span class="headercktext" style="width: 130px;"><?php echo JText::_('CK_ELEMENTS'); ?></span>
|
||||
<span class="ckbutton-group" style="margin: 5px;">
|
||||
<span class="headerckdisplaytype ckbutton <?php echo ($displaytype == 'list' ? 'active' : '') ?>" data-type="list" onclick="ckSetAddonsDisplaytypeState('list')"><i class="fa fa-list cktip" data-placement="bottom" title="<?php echo JText::_('CK_DISPLAY_TYPE_LIST') ?>" onclick="ckSearchAddon(this)"></i></span>
|
||||
<span class="headerckdisplaytype ckbutton <?php echo ($displaytype == 'grid' ? 'active' : '') ?>" data-type="grid" onclick="ckSetAddonsDisplaytypeState('grid')"><i class="fa fa-th cktip" data-placement="bottom" title="<?php echo JText::_('CK_DISPLAY_TYPE_GRID') ?>" onclick="ckSearchAddon(this)"></i></span>
|
||||
</span>
|
||||
</div>
|
||||
<div id="ckaddonsearch" class="ckleftpanelsearch">
|
||||
<input type="text" class="cksearchleftpanel" placeholder="<?php echo JText::_('CK_SEARCH') ?>" onchange="ckSearchAddon(this)" />
|
||||
<i class="fa fa-search cktip" title="<?php echo JText::_('CK_SEARCH') ?>" onclick="ckSearchAddon(this)"></i>
|
||||
<i class="fa fa-times cktip" title="<?php echo JText::_('CK_CLEAN') ?>" onclick="ckSearchAddonClear()"></i>
|
||||
</div>
|
||||
<div class="menuckinfos"><?php echo JText::_('COM_PAGEBUILDERCK_INSERT_CONTENT'); ?></div>
|
||||
<?php
|
||||
// $items = Pagebuilderck\CKFof::triggerEvent( 'onPagebuilderckAddItemToMenu' );
|
||||
$items = PagebuilderckHelper::getPluginsMenuItemType();
|
||||
$groups = PagebuilderckHelper::getPluginsMenuItemTypeByGroup();
|
||||
?>
|
||||
<div id="ckaddonsdisplaytypegrid" class="ckaddonsdisplaytype">
|
||||
<?php
|
||||
$pagebuilderckTypesImagesArray = array();
|
||||
if (count($items)) {
|
||||
foreach ($items as $item) {
|
||||
$pagebuilderckTypesImagesArray[$item->type] = $item->image;
|
||||
?>
|
||||
<div data-type="<?php echo $item->type ?>" data-group="<?php echo $item->group ?>" class="menuitemck" title="<b><?php echo $item->title ?></b><br /><?php echo $item->description ?>">
|
||||
<div>
|
||||
<div class="menuitemck_title"><?php echo $item->title ?></div>
|
||||
</div>
|
||||
<img src="<?php echo $item->image ?>" />
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<div id="ckaddonsdisplaytypelist" class="ckaddonsdisplaytype">
|
||||
<?php
|
||||
foreach ($groups as $groupname => $group) {
|
||||
if (empty($group['items'])) continue;
|
||||
?>
|
||||
<div class="menuitemck_group"><?php echo $group['name'] ?></div>
|
||||
<div>
|
||||
<?php
|
||||
foreach ($group['items'] as $item) {
|
||||
$pagebuilderckTypesImagesArray[$item->type] = $item->image;
|
||||
?>
|
||||
<div data-type="<?php echo $item->type ?>" data-group="<?php echo $item->group ?>" class="menuitemck" title="<b><?php echo $item->title ?></b><br /><?php echo $item->description ?>">
|
||||
<div>
|
||||
<div class="menuitemck_title"><?php echo $item->title ?></div>
|
||||
</div>
|
||||
<img src="<?php echo $item->image ?>" />
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
<div style="clear:both;"></div>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<div style="clear:both;"></div>
|
||||
<div><?php echo PagebuilderckHelper::showParamsMessage(true, JText::_('CK_PAGEBUILDERCK_GETMORE_PRO_ITEMS')); ?></div>
|
||||
<div class="headerck ckmyelements" style="clear:both;">
|
||||
<span class="headercktext"><?php echo JText::_('CK_MY_ELEMENTS'); ?></span>
|
||||
</div>
|
||||
<div class="" id="ckmyelements">
|
||||
<?php
|
||||
$elements = PagebuilderckHelper::getElements();
|
||||
if (count($elements)) {
|
||||
foreach ($elements as $element) {
|
||||
if (($view == 'element' || $view == 'style') && $element->type == 'row') continue;
|
||||
$description = $element->description ? $element->description : $element->title;
|
||||
?>
|
||||
<div data-type="<?php echo $element->type ?>" data-id="<?php echo $element->id ?>" class="menuitemck ckmyelement" title="<b><?php echo $description ?></b>">
|
||||
<div>
|
||||
<div class="menuitemck_title"><?php echo $element->title ?></div>
|
||||
</div>
|
||||
<img src="<?php echo isset($pagebuilderckTypesImagesArray[$element->type]) ? $pagebuilderckTypesImagesArray[$element->type] : PAGEBUILDERCK_MEDIA_URI . '/images/contents/' . $element->type . '.svg' ?>" />
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="inner clearfix ckelementsedition menuckpaneltarget" data-target="pages">
|
||||
<div class="headerck">
|
||||
<span class="headercktext"><?php echo JText::_('CK_PAGES'); ?></span>
|
||||
</div>
|
||||
<iframe class="ckwait" src="index.php?option=com_pagebuilderck&view=pages&layout=modal&tmpl=component&function=returnLoadPage&target=leftpanel" width="100%" height="auto" >
|
||||
</iframe>
|
||||
</div>
|
||||
<div class="inner clearfix ckelementsedition menuckpaneltarget" data-target="styles">
|
||||
<div class="headerck">
|
||||
<span class="headercktext"><?php echo JText::_('CK_STYLES'); ?></span>
|
||||
</div>
|
||||
<?php if (PagebuilderckHelper::getParams()) { ?>
|
||||
<iframe id="pbckiframestyles" class="ckwait" src="index.php?option=com_pagebuilderck&view=styles&layout=modal&tmpl=component&function=ckReturnLoadStyle&target=leftpanel" width="100%" height="auto" >
|
||||
</iframe>
|
||||
<?php } else {
|
||||
echo PagebuilderckHelper::showParamsMessage();
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<div class="inner clearfix ckelementsedition menuckpaneltarget" data-target="library">
|
||||
<div class="headerck">
|
||||
<span class="headercktext"><?php echo JText::_('CK_MODELS'); ?></span>
|
||||
</div>
|
||||
<?php if (PagebuilderckHelper::getParams()) { ?>
|
||||
<div id="cklibraryiframe"><?php PagebuilderckHelper::loadCustomLibrary() ?></div>
|
||||
<?php } else {
|
||||
echo PagebuilderckHelper::showParamsMessage();
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<div class="inner clearfix ckresponsiveedition menuckpaneltarget" data-target="responsive">
|
||||
<div class="menuckcollapse headerck">
|
||||
<span class="headercktext" style="width:auto;"><?php echo JText::_('CK_RESPONSIVE_SETTINGS'); ?></span>
|
||||
<?php /*<span class="headerckicon cktip" title="<?php echo JText::_('CK_SAVE_CLOSE'); ?>" onclick="ckShowResponsiveSettings(true);">×</span> */ ?>
|
||||
</div>
|
||||
<div id="cktoolbarResponsive" class="clearfix ckinterface cktoolbarResponsive" style="overflow:visible;background:none;padding:5px;">
|
||||
<span class="ckbutton-group">
|
||||
<span id="ckresponsive1button" class="ckbutton ckresponsivebutton" onclick="ckSwitchResponsive(1)" data-range="1">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M976 1408q0-33-23.5-56.5t-56.5-23.5-56.5 23.5-23.5 56.5 23.5 56.5 56.5 23.5 56.5-23.5 23.5-56.5zm208-160v-704q0-13-9.5-22.5t-22.5-9.5h-512q-13 0-22.5 9.5t-9.5 22.5v704q0 13 9.5 22.5t22.5 9.5h512q13 0 22.5-9.5t9.5-22.5zm-192-848q0-16-16-16h-160q-16 0-16 16t16 16h160q16 0 16-16zm288-16v1024q0 52-38 90t-90 38h-512q-52 0-90-38t-38-90v-1024q0-52 38-90t90-38h512q52 0 90 38t38 90z"/></svg>
|
||||
<?php echo JText::_('CK_PHONE') ?> / <small><?php echo JText::_('CK_PORTRAIT') ?></small></span>
|
||||
<input id="ckresponsive1value" type="text" value="<?php echo $componentParams->get('responsive1value', '320') ?>" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
</span>
|
||||
<span class="ckbutton-group">
|
||||
<span id="ckresponsive2button" class="ckbutton ckresponsivebutton" onclick="ckSwitchResponsive(2)" data-range="2">
|
||||
<svg style="vertical-align: bottom;transform:rotate(90deg);" width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M976 1408q0-33-23.5-56.5t-56.5-23.5-56.5 23.5-23.5 56.5 23.5 56.5 56.5 23.5 56.5-23.5 23.5-56.5zm208-160v-704q0-13-9.5-22.5t-22.5-9.5h-512q-13 0-22.5 9.5t-9.5 22.5v704q0 13 9.5 22.5t22.5 9.5h512q13 0 22.5-9.5t9.5-22.5zm-192-848q0-16-16-16h-160q-16 0-16 16t16 16h160q16 0 16-16zm288-16v1024q0 52-38 90t-90 38h-512q-52 0-90-38t-38-90v-1024q0-52 38-90t90-38h512q52 0 90 38t38 90z"/></svg>
|
||||
<?php echo JText::_('CK_PHONE') ?> / <small><?php echo JText::_('CK_LANDSCAPE') ?></small></span>
|
||||
<input id="ckresponsive2value" type="text" value="<?php echo $componentParams->get('responsive2value', '480') ?>" class="cktip" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
</span>
|
||||
<span class="ckbutton-group">
|
||||
<span id="ckresponsive3button" class="ckbutton ckresponsivebutton" onclick="ckSwitchResponsive(3)" data-range="3">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M960 1408q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm384-160v-960q0-13-9.5-22.5t-22.5-9.5h-832q-13 0-22.5 9.5t-9.5 22.5v960q0 13 9.5 22.5t22.5 9.5h832q13 0 22.5-9.5t9.5-22.5zm128-960v1088q0 66-47 113t-113 47h-832q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h832q66 0 113 47t47 113z"/></svg>
|
||||
<?php echo JText::_('CK_TABLET') ?> / <small><?php echo JText::_('CK_PORTRAIT') ?></small></span>
|
||||
<input id="ckresponsive3value" type="text" value="<?php echo $componentParams->get('responsive3value', '640') ?>" class="cktip" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
</span>
|
||||
<span class="ckbutton-group">
|
||||
<span id="ckresponsive4button" class="ckbutton ckresponsivebutton" onclick="ckSwitchResponsive(4)" data-range="4">
|
||||
<svg style="vertical-align: bottom;transform:rotate(90deg);" width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M960 1408q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm384-160v-960q0-13-9.5-22.5t-22.5-9.5h-832q-13 0-22.5 9.5t-9.5 22.5v960q0 13 9.5 22.5t22.5 9.5h832q13 0 22.5-9.5t9.5-22.5zm128-960v1088q0 66-47 113t-113 47h-832q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h832q66 0 113 47t47 113z"/></svg>
|
||||
<?php echo JText::_('CK_TABLET') ?> / <small><?php echo JText::_('CK_LANDSCAPE') ?></small></span>
|
||||
<input id="ckresponsive4value" type="text" value="<?php echo $componentParams->get('responsive4value', '800') ?>" class="cktip" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
</span>
|
||||
<span>
|
||||
<span id="ckresponsive5button" class="ckbutton ckresponsivebutton" onclick="ckSwitchResponsive(5)" data-range="5">
|
||||
<svg width="2048" height="1792" viewBox="0 0 2048 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1856 992v-832q0-13-9.5-22.5t-22.5-9.5h-1600q-13 0-22.5 9.5t-9.5 22.5v832q0 13 9.5 22.5t22.5 9.5h1600q13 0 22.5-9.5t9.5-22.5zm128-832v1088q0 66-47 113t-113 47h-544q0 37 16 77.5t32 71 16 43.5q0 26-19 45t-45 19h-512q-26 0-45-19t-19-45q0-14 16-44t32-70 16-78h-544q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h1600q66 0 113 47t47 113z"/></svg>
|
||||
<?php echo JText::_('CK_COMPUTER') ?>
|
||||
</span>
|
||||
</span>
|
||||
<p><?php echo JText::_('CK_EDIT_RESPONSIVE_COLUMNS_DESC') ?></p>
|
||||
<div class="ckinterface">
|
||||
<span class="ckbuttonstyle" onclick="ckSwitchResponsiveEditColumns(this)" data-state="0">
|
||||
<svg style="width:20px;height:24px;stroke:#fff;vertical-align: bottom;" xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-columns-2" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M3 3m0 1a1 1 0 0 1 1 -1h16a1 1 0 0 1 1 1v16a1 1 0 0 1 -1 1h-16a1 1 0 0 1 -1 -1zm9 -1v18" />
|
||||
</svg>
|
||||
<?php echo JText::_('CK_EDIT_RESPONSIVE_COLUMNS') ?>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="inner clearfix ckcolumnsedition" >
|
||||
<div class="headerck">
|
||||
<span class="headerckicon" onclick="ckHideColumnsEdition()">×</span>
|
||||
<span class="headercktext"><?php echo JText::_('CK_COLUMNS'); ?></span>
|
||||
</div>
|
||||
<div class="ckcolumnsoptions">
|
||||
<div class="ckbutton-group" style="margin-top: 5px;">
|
||||
<input id="autowidth" name="autowidth" value="1" type="radio" onchange="ckUpdateAutowidth($ck('.rowck.ckfocus'), this.value);" />
|
||||
<label class="ckbutton btn" for="autowidth" style="width:auto;margin-left:5px;" ><?php echo JText::_('CK_AUTO_WIDTH') ?></label>
|
||||
<input id="advlayout" name="autowidth" value="0" type="radio" onchange="ckUpdateAutowidth($ck('.rowck.ckfocus'), this.value);" />
|
||||
<label class="ckbutton btn" for="advlayout" style="width:auto;"><?php echo JText::_('CK_ADVANCED_LAYOUT') ?></label>
|
||||
</div>
|
||||
<div id="ckgutteroptions">
|
||||
<div class="menuckinfos"><?php echo JText::_('CK_GUTTER') ?></div>
|
||||
<input class="ckguttervalue" type="text" onchange="ckUpdateGutter($ck('.rowck.ckfocus'), this.value);" style="margin-left:5px;" />
|
||||
</div>
|
||||
<div>
|
||||
<div class="ckbuttonstyle" onclick="ckAddBlock($ck('.rowck.ckfocus'));" style="display: block;">+ <?php echo JText::_('CK_ADD_COLUMN') ?></div>
|
||||
</div>
|
||||
<div class="menuckinfos"><?php echo JText::_('CK_COLUMNS_SPACE_BETWEEN') ?></div>
|
||||
<div class="ckbutton-group" style="margin-top: 5px;">
|
||||
<input id="columns-space-between0" name="columns-space-between" value="0" type="radio" onchange="ckUpdateSpacebetween($ck('.rowck.ckfocus'), this.value);" />
|
||||
<label class="ckbutton btn" for="columns-space-between0" style="width:auto;margin-left:5px;" ><?php echo JText::_('JNO') ?></label>
|
||||
<input id="columns-space-between1" name="columns-space-between" value="1" type="radio" onchange="ckUpdateSpacebetween($ck('.rowck.ckfocus'), this.value);" />
|
||||
<label class="ckbutton btn" for="columns-space-between1" style="width:auto;"><?php echo JText::_('JYES') ?></label>
|
||||
</div>
|
||||
<div id="ckcolumnsuggestions">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="menuckbootomtoolbar">
|
||||
<span id="togglepanel" class="menuckbootomtoolbar-button cktip" onclick="ckTogglePanel()" title="<?php echo JText::_('CK_TOGGLE_PANEL') ?>">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-chevron-left" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M15 6l-6 6l6 6" />
|
||||
</svg>
|
||||
</span>
|
||||
<?php if ($input->get('id', 0, 'int')
|
||||
&& $input->get('option', '', 'cmd') == 'com_pagebuilderck'
|
||||
&& $input->get('view', '', 'cmd') == 'page'
|
||||
&& \Pagebuilderck\CKFof::isAdmin()){ ?>
|
||||
<a class="" target="_blank" href="<?php echo JUri::root(true) ?>/index.php?option=com_pagebuilderck&view=page&id=<?php echo $input->get('id', '', 'int') ?>"><span class="menuckbootomtoolbar-button cktip" title="<?php echo JText::_('CK_PREVIEW_FRONT') ?>">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-eye-check" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M10 12a2 2 0 1 0 4 0a2 2 0 0 0 -4 0" />
|
||||
<path d="M11.143 17.961c-3.221 -.295 -5.936 -2.281 -8.143 -5.961c2.4 -4 5.4 -6 9 -6c3.6 0 6.6 2 9 6c-.222 .37 -.449 .722 -.68 1.057" />
|
||||
<path d="M15 19l2 2l4 -4" />
|
||||
</svg>
|
||||
</a>
|
||||
<?php } else if ($input->get('id', 0, 'int') && $input->get('option', '', 'cmd') == 'com_content' && $input->get('view', '', 'cmd') == 'article' && \Pagebuilderck\CKFof::isAdmin()) { ?>
|
||||
<a class="" target="_blank" href="<?php echo JUri::root(true) ?>/index.php?option=com_content&view=article&id=<?php echo $input->get('id', '', 'int') ?>"><span class="menuckbootomtoolbar-button cktip" title="<?php echo JText::_('CK_PREVIEW_FRONT') ?>">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-eye-check" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M10 12a2 2 0 1 0 4 0a2 2 0 0 0 -4 0" />
|
||||
<path d="M11.143 17.961c-3.221 -.295 -5.936 -2.281 -8.143 -5.961c2.4 -4 5.4 -6 9 -6c3.6 0 6.6 2 9 6c-.222 .37 -.449 .722 -.68 1.057" />
|
||||
<path d="M15 19l2 2l4 -4" />
|
||||
</svg>
|
||||
</a>
|
||||
<?php }?>
|
||||
<?php if (
|
||||
($input->get('option', '', 'cmd') == 'com_content' && $input->get('view', '', 'cmd') == 'article' && \Pagebuilderck\CKFof::isAdmin())
|
||||
|| ($input->get('option', '', 'cmd') == 'com_flexicontent' && $input->get('view', '', 'cmd') == 'article' && \Pagebuilderck\CKFof::isAdmin())
|
||||
|| ($input->get('option', '', 'cmd') == 'com_modules' && $input->get('view', '', 'cmd') == 'module' && \Pagebuilderck\CKFof::isAdmin())
|
||||
|| ($input->get('option', '', 'cmd') == 'com_advmodulesmanager' && $input->get('view', '', 'cmd') == 'module' && \Pagebuilderck\CKFof::isAdmin())
|
||||
) { ?>
|
||||
<span class="menuckbootomtoolbar-button cktip" onclick="ckSaveAsPage()" title="<?php echo JText::_('CK_SAVE_AS_PAGE') ?>">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-device-floppy" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M6 4h10l4 4v10a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2" />
|
||||
<path d="M12 14m-2 0a2 2 0 1 0 4 0a2 2 0 1 0 -4 0" />
|
||||
<path d="M14 4l0 4l-6 0l0 -4" />
|
||||
</svg>
|
||||
</span>
|
||||
<?php } ?>
|
||||
<span id="ckhtmlchecksettingsbutton" class="menuckbootomtoolbar-button cktip" onclick="ckCheckHtml()" title="<?php echo JText::_('CK_HTML_CSS') ?>">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-focus" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<circle cx="12" cy="12" r=".5" fill="currentColor" />
|
||||
<path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0" />
|
||||
</svg>
|
||||
</span>
|
||||
<span id="ckundo" class="menuckbootomtoolbar-button cktip" onclick="ckUndo()" title="<?php echo JText::_('CK_UNDO') ?>">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-arrow-back-up" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M9 14l-4 -4l4 -4" />
|
||||
<path d="M5 10h11a4 4 0 1 1 0 8h-1" />
|
||||
</svg>
|
||||
</span>
|
||||
<span id="ckundo" class="menuckbootomtoolbar-button cktip" onclick="ckRedo()" title="<?php echo JText::_('CK_REDO') ?>">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-arrow-forward-up" width="44" height="44" viewBox="0 0 24 24" stroke-width="1.5" stroke="#2c3e50" fill="none" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path stroke="none" d="M0 0h24v24H0z" fill="none"/>
|
||||
<path d="M15 14l4 -4l-4 -4" />
|
||||
<path d="M19 10h-11a4 4 0 1 0 0 8h1" />
|
||||
</svg>
|
||||
</span>
|
||||
</div>
|
||||
<div id="ckcustomcssedition" style="display: none;"></div>
|
||||
</div>
|
||||
<?php
|
||||
// if contenttype, only load the plugins with scripts
|
||||
} else {
|
||||
// load the custom plugins
|
||||
JPluginHelper::importPlugin( 'pagebuilderck' );
|
||||
$otheritems = Pagebuilderck\CKFof::triggerEvent( 'onPagebuilderckAddItemToMenu' );
|
||||
}
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
// check if we are in frontend
|
||||
var isSiteCK = '<?php echo \Pagebuilderck\CKFof::isSite() ?>';
|
||||
$ck('#menuck').hide();
|
||||
|
||||
var ckcustomcsseditor;
|
||||
$ck(document).ready(function (){
|
||||
// create tooltip for the items
|
||||
ckMakeTooltip($ck('#menuck .menuitemck'));
|
||||
$ck('#menuck').fadeIn();
|
||||
});
|
||||
|
||||
if (isSiteCK) {
|
||||
$ck(window).on("load resize scroll", function() {
|
||||
if (! $ck('#workspaceck').length || ! $ck('#workspaceparentck').length) return;
|
||||
var menuToWorkspaceOffset = $ck('#workspaceparentck').offset().left -50 - $ck('#menuck').width()
|
||||
if (menuToWorkspaceOffset < 0) {
|
||||
$ck('#workspaceck').css({'margin-left': -menuToWorkspaceOffset + 'px'});
|
||||
} else {
|
||||
$ck('#workspaceck').css({'margin-left': '0'});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
$ck('.menuckpanel').click(function() {
|
||||
ckActivatePanel($ck(this).attr('data-target'));
|
||||
});
|
||||
|
||||
$ck('#ckcustomcsssettingsbutton').click(function() {
|
||||
ckOpenCustomCssEditor();
|
||||
});
|
||||
|
||||
$ck('.menuitemck_group').click(function() {
|
||||
$ck(this).find('+ div').toggle('fast');
|
||||
});
|
||||
|
||||
</script>
|
||||
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
$user = JFactory::getUser();
|
||||
$app = JFactory::getApplication();
|
||||
|
||||
$assoc = isset($app->item_associations) ? $app->item_associations : 0;
|
||||
$canEdit = $user->authorise('core.edit', 'com_pagebuilderck');
|
||||
?>
|
||||
|
||||
<?php
|
||||
// loads the css and js files
|
||||
include PAGEBUILDERCK_PATH . '/views/page/tmpl/include.php';
|
||||
?>
|
||||
|
||||
<button id="applyBtn" type="button" style="display:none;" onclick="Joomla.submitbutton('page.apply');"></button>
|
||||
<button id="saveBtn" type="button" style="display:none;" onclick="Joomla.submitbutton('page.save');"></button>
|
||||
<button id="closeBtn" type="button" style="display:none;" onclick="Joomla.submitbutton('page.cancel');"></button>
|
||||
<?php
|
||||
// loads the context menu
|
||||
include PAGEBUILDERCK_PATH . '/views/page/tmpl/main.php';
|
||||
include PAGEBUILDERCK_PATH . '/views/page/tmpl/contextmenu.php';
|
||||
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
?>
|
||||
|
||||
<input type="hidden" id="options_showtitle" name="options[showtitle]" value="<?php echo $params->get('showtitle') ?>" />
|
||||
<input type="hidden" id="options_titletag" name="options[titletag]" value="<?php echo $params->get('titletag') ?>" />
|
||||
<div class="clearfix">
|
||||
<label for="options_titletag" id="options_categories-lbl">
|
||||
<?php echo JText::_('COM_PAGEBUILDERCK_CATEGORIES'); ?>
|
||||
</label>
|
||||
<select id="categories" name="categories[]" multiple="true" class="form-control">
|
||||
<?php
|
||||
$categories = PagebuilderckHelper::getCategories();
|
||||
foreach ($categories as $category) {
|
||||
?>
|
||||
<option value="<?php echo $category->id ?>" <?php echo (in_array($category->id, $this->item->categories) ?'selected="true"':'') ?>><?php echo $category->name ?></option>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="clearfix">
|
||||
<label for="options_contentprepare" id="options_contentprepare-lbl">
|
||||
<?php echo JText::_('COM_PAGEBUILDERCK_CONTENT_PREPARE'); ?>
|
||||
</label>
|
||||
<fieldset id="options_contentprepare-fieldset" class="radio btn-group">
|
||||
<input id="options_contentprepare0" type="radio" <?php echo ($params->get('contentprepare')==0?'checked="checked"':'') ?> value="0" name="options[contentprepare]">
|
||||
<label class="btn" for="options_contentprepare0"><?php echo JText::_('JNO') ?></label>
|
||||
<input id="options_contentprepare1" type="radio" <?php echo ($params->get('contentprepare')==1?'checked="checked"':'') ?> value="1" name="options[contentprepare]">
|
||||
<label class="btn" for="options_contentprepare1"><?php echo JText::_('JYES') ?></label>
|
||||
</fieldset>
|
||||
</div>
|
||||
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
$componentParams = JComponentHelper::getParams('com_pagebuilderck');
|
||||
?>
|
||||
<div id="cktoolbarResponsive" class="cktoolbarResponsive clearfix ckinterface" style="overflow:visible;background:none;padding:5px;text-align:center;">
|
||||
<span class="ckbutton-group">
|
||||
<span id="ckresponsive1button" class="ckbutton ckresponsivebutton cktip" style="width: auto;" onclick="ckSwitchResponsive(1)" data-range="1" title="<?php echo JText::_('CK_PHONE') ?> / <?php echo JText::_('CK_PORTRAIT') ?>">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M976 1408q0-33-23.5-56.5t-56.5-23.5-56.5 23.5-23.5 56.5 23.5 56.5 56.5 23.5 56.5-23.5 23.5-56.5zm208-160v-704q0-13-9.5-22.5t-22.5-9.5h-512q-13 0-22.5 9.5t-9.5 22.5v704q0 13 9.5 22.5t22.5 9.5h512q13 0 22.5-9.5t9.5-22.5zm-192-848q0-16-16-16h-160q-16 0-16 16t16 16h160q16 0 16-16zm288-16v1024q0 52-38 90t-90 38h-512q-52 0-90-38t-38-90v-1024q0-52 38-90t90-38h512q52 0 90 38t38 90z"/></svg>
|
||||
</span>
|
||||
<input id="ckresponsive1value" type="hidden" value="<?php echo $componentParams->get('responsive1value', '320') ?>" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
|
||||
<span id="ckresponsive2button" class="ckbutton ckresponsivebutton cktip" style="width: auto;" onclick="ckSwitchResponsive(2)" data-range="2" title="<?php echo JText::_('CK_PHONE') ?> / <?php echo JText::_('CK_LANDSCAPE') ?>">
|
||||
<svg style="font-size: 1.4em;vertical-align: bottom;transform:rotate(90deg);" width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M976 1408q0-33-23.5-56.5t-56.5-23.5-56.5 23.5-23.5 56.5 23.5 56.5 56.5 23.5 56.5-23.5 23.5-56.5zm208-160v-704q0-13-9.5-22.5t-22.5-9.5h-512q-13 0-22.5 9.5t-9.5 22.5v704q0 13 9.5 22.5t22.5 9.5h512q13 0 22.5-9.5t9.5-22.5zm-192-848q0-16-16-16h-160q-16 0-16 16t16 16h160q16 0 16-16zm288-16v1024q0 52-38 90t-90 38h-512q-52 0-90-38t-38-90v-1024q0-52 38-90t90-38h512q52 0 90 38t38 90z"/></svg>
|
||||
</span>
|
||||
<input id="ckresponsive2value" type="hidden" value="<?php echo $componentParams->get('responsive2value', '480') ?>" class="cktip" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
</span>
|
||||
<span class="ckbutton-group">
|
||||
<span id="ckresponsive3button" class="ckbutton ckresponsivebutton cktip" style="width: auto;" onclick="ckSwitchResponsive(3)" data-range="3" title="<?php echo JText::_('CK_TABLET') ?> / <?php echo JText::_('CK_PORTRAIT') ?>">
|
||||
<svg width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M960 1408q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm384-160v-960q0-13-9.5-22.5t-22.5-9.5h-832q-13 0-22.5 9.5t-9.5 22.5v960q0 13 9.5 22.5t22.5 9.5h832q13 0 22.5-9.5t9.5-22.5zm128-960v1088q0 66-47 113t-113 47h-832q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h832q66 0 113 47t47 113z"/></svg>
|
||||
</span>
|
||||
<input id="ckresponsive3value" type="hidden" value="<?php echo $componentParams->get('responsive3value', '640') ?>" class="cktip" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
<span id="ckresponsive4button" class="ckbutton ckresponsivebutton cktip" style="width: auto;" onclick="ckSwitchResponsive(4)" data-range="4" title="<?php echo JText::_('CK_TABLET') ?> / <?php echo JText::_('CK_LANDSCAPE') ?>">
|
||||
<svg style="vertical-align: bottom;transform:rotate(90deg);" width="1792" height="1792" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M960 1408q0-26-19-45t-45-19-45 19-19 45 19 45 45 19 45-19 19-45zm384-160v-960q0-13-9.5-22.5t-22.5-9.5h-832q-13 0-22.5 9.5t-9.5 22.5v960q0 13 9.5 22.5t22.5 9.5h832q13 0 22.5-9.5t9.5-22.5zm128-960v1088q0 66-47 113t-113 47h-832q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h832q66 0 113 47t47 113z"/></svg>
|
||||
</span>
|
||||
<input id="ckresponsive4value" type="hidden" value="<?php echo $componentParams->get('responsive4value', '800') ?>" class="cktip" data-default="" disabled="disabled" title="<?php echo JText::_('CK_SET_RESPONSIVE_VALUE_IN_OPTIONS') ?>" style="width:40px;"/>
|
||||
</span>
|
||||
<span>
|
||||
<span id="ckresponsive5button" class="ckbutton ckresponsivebutton ckbutton-warning active cktip" style="width: auto;" onclick="ckSwitchResponsive(5)" data-range="5" title="<?php echo JText::_('CK_COMPUTER') ?>">
|
||||
<svg width="2048" height="1792" viewBox="0 0 2048 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1856 992v-832q0-13-9.5-22.5t-22.5-9.5h-1600q-13 0-22.5 9.5t-9.5 22.5v832q0 13 9.5 22.5t22.5 9.5h1600q13 0 22.5-9.5t9.5-22.5zm128-832v1088q0 66-47 113t-113 47h-544q0 37 16 77.5t32 71 16 43.5q0 26-19 45t-45 19h-512q-26 0-45-19t-19-45q0-14 16-44t32-70 16-78h-544q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h1600q66 0 113 47t47 113z"/></svg>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2020. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
defined('_JEXEC') or die;
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
<?php if (Pagebuilderck\CKFof::getInput()->get('option') == 'com_pagebuilderck') { ?>
|
||||
// override to avoid it to be called;
|
||||
if (typeof(Joomla) != 'undefined') {
|
||||
// Joomla.submitbutton = function() {
|
||||
// alert('ok Joomla.submitbutton');
|
||||
// };
|
||||
}
|
||||
document.formvalidator = function() {}
|
||||
document.formvalidator.isValid = function(form) {return true;}
|
||||
<?php } ?>
|
||||
|
||||
var ckcontentform;
|
||||
|
||||
$ck(document).ready(function() {
|
||||
if (! ckcontentform) {
|
||||
ckcontentform = document.getElementById("module-form")
|
||||
|| document.getElementById("modules-form")
|
||||
|| document.getElementById("item-form")
|
||||
|| document.getElementById("adminForm");
|
||||
}
|
||||
|
||||
ckcontentform.onsubmit = function(e) {
|
||||
event.preventDefault();
|
||||
var task = ckcontentform.task.value;
|
||||
if (task == 'page.restore') {
|
||||
ckCallRestorePopup();
|
||||
} else {
|
||||
if ((task.includes('page.save') || task.includes('page.apply')) && ckcontentform.title.value == '') {
|
||||
ckcontentform.title.className += ' invalid';
|
||||
alert('<?php echo JText::_('CK_TITLE_EMPTY') ?>');
|
||||
return;
|
||||
}
|
||||
if (! task.includes('.cancel')) {
|
||||
var workspace = $ck('#workspaceck').length ? $ck('#workspaceck') : $ck('.workspaceck');
|
||||
// delete all unwanted interface elements in the final code
|
||||
ckCleanInterfaceBeforeSave(workspace);
|
||||
// replace the base path to keep images during website migration
|
||||
if (PAGEBUILDERCK.URIROOT != '' && PAGEBUILDERCK.URIROOT != '/') {
|
||||
var replaceUriroot = new RegExp('src="' + PAGEBUILDERCK.URIROOT, "g");
|
||||
workspace.html(workspace.html().replace(replaceUriroot, 'src="|URIROOT|'));
|
||||
}
|
||||
|
||||
if ($ck('#htmlcode').length) $ck('#htmlcode').val(workspace.html());
|
||||
|
||||
// check if the function exists, loads it
|
||||
if (typeof JoomlaCK.beforesubmitbutton == 'function') { JoomlaCK.beforesubmitbutton(); }
|
||||
}
|
||||
|
||||
// send the form
|
||||
ckcontentform.submit();
|
||||
}
|
||||
}
|
||||
});</script>
|
||||
@@ -0,0 +1,59 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
// No direct access to this file
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
jimport('joomla.filesystem.file');
|
||||
jimport('joomla.filesystem.folder');
|
||||
$app = JFactory::getApplication();
|
||||
$input = $app->input;
|
||||
// get global component params
|
||||
$componentParams = JComponentHelper::getParams('com_pagebuilderck');
|
||||
?>
|
||||
<div id="cktoolbarLoadPageOptions" class="clearfix" style="display:none;">
|
||||
<div class="">
|
||||
<h1>
|
||||
<?php echo JText::_('CK_SELECT') ?>
|
||||
<div style="font-size:10px;white-space:nowrap;margin-top:-7px;"><?php echo JText::_('CK_OPTIONS') ?></div>
|
||||
</h1>
|
||||
</div>
|
||||
<div style="border-top: 1px solid #ddd;">
|
||||
<br />
|
||||
<p><?php echo JText::_('CK_HOW_TO_LOAD_PAGE') ?></p>
|
||||
<br />
|
||||
<div class="cktoolbar" class="clearfix" style="text-align:center;">
|
||||
<span class="ckbutton ckaction" onclick="ckLoadPage(this, 'replace')"><?php echo JText::_('CK_REPLACE') ?></span>
|
||||
<span class="ckbutton ckaction" onclick="ckLoadPage(this, 'top')"><?php echo JText::_('CK_TOP_PAGE') ?></span>
|
||||
<span class="ckbutton ckaction" onclick="ckLoadPage(this, 'bottom')"><?php echo JText::_('CK_END_PAGE') ?></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="cktoolbarExportPage" class="clearfix" style="display:none;">
|
||||
<div class="">
|
||||
<h1>
|
||||
<?php echo JText::_('CK_EXPORT_TO_PAGE') ?>
|
||||
<div style="font-size:10px;white-space:nowrap;margin-top:-7px;"><?php echo JText::_('CK_OPTIONS') ?></div>
|
||||
</h1>
|
||||
</div>
|
||||
<div style="border-top: 1px solid #ddd;">
|
||||
<br />
|
||||
<p><?php echo JText::_('CK_HOW_TO_LOAD_PAGE') ?></p>
|
||||
<br />
|
||||
<div class="cktoolbar" class="clearfix" style="text-align:center;">
|
||||
<span class="ckbutton ckaction" onclick="ckLoadPage(this, 'replace')"><?php echo JText::_('CK_REPLACE') ?></span>
|
||||
<span class="ckbutton ckaction" onclick="ckLoadPage(this, 'top')"><?php echo JText::_('CK_TOP_PAGE') ?></span>
|
||||
<span class="ckbutton ckaction" onclick="ckLoadPage(this, 'bottom')"><?php echo JText::_('CK_END_PAGE') ?></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php
|
||||
if ($favoriteClass = PagebuilderckHelper::getParams('favorites')) {
|
||||
$favoriteClass->loadStylesPanel();
|
||||
}
|
||||
// load the params message in the page
|
||||
echo PagebuilderckHelper::showParamsMessage(false);
|
||||
@@ -0,0 +1,94 @@
|
||||
<?php
|
||||
/**
|
||||
* @name Page Builder CK
|
||||
* @package com_pagebuilderck
|
||||
* @copyright Copyright (C) 2015. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
* @author Cedric Keiflin - https://www.template-creator.com - https://www.joomlack.fr
|
||||
*/
|
||||
|
||||
// No direct access
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Pagebuilderck\CKView;
|
||||
use Pagebuilderck\CKFof;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
class PagebuilderckViewPage extends CKView {
|
||||
|
||||
protected $ckeditor;
|
||||
|
||||
protected $elements;
|
||||
|
||||
function display($tpl = null) {
|
||||
include_once JPATH_ADMINISTRATOR . '/components/com_pagebuilderck/helpers/menustyles.php';
|
||||
include_once JPATH_ADMINISTRATOR . '/components/com_pagebuilderck/helpers/stylescss.php';
|
||||
include_once JPATH_ADMINISTRATOR . '/components/com_pagebuilderck/helpers/ckeditor.php';
|
||||
include_once JPATH_ADMINISTRATOR . '/components/com_pagebuilderck/helpers/pagebuilderck.php';
|
||||
|
||||
JToolBarHelper::title(JText::_('COM_PAGEBUILDERCK'), 'home_pagebuilderck');
|
||||
|
||||
PagebuilderckHelper::checkTableExists('fonts');
|
||||
|
||||
// get instance of the editor to load the css / js in the page
|
||||
$this->ckeditor = PagebuilderckHelper::loadEditor();
|
||||
$this->item = $this->get('Item');
|
||||
$this->elements = $this->get('Elements');
|
||||
|
||||
$user = CKFof::getUser();
|
||||
$authorised = ($user->authorise('core.create', 'com_pagebuilderck') || (count($user->getAuthorisedCategories('com_pagebuilderck', 'core.create'))));
|
||||
|
||||
if ($authorised !== true)
|
||||
{
|
||||
throw new Exception(JText::_('JERROR_ALERTNOAUTHOR'), 403);
|
||||
return false;
|
||||
}
|
||||
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
// exit to make a full edition standalone page
|
||||
if ($this->input->get('display') === 'raw') {
|
||||
exit();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*
|
||||
* @since 1.6
|
||||
*/
|
||||
protected function addToolbar() {
|
||||
|
||||
$this->input->set('hidemainmenu', true);
|
||||
$user = CKFof::getUser();
|
||||
$userId = $user->get('id');
|
||||
$isNew = ($this->item->id == 0 || $this->item->id == "");
|
||||
$checkedOut = !($this->item->checked_out == 0 || $this->item->checked_out == $userId);
|
||||
|
||||
JToolBarHelper::title(JText::_('COM_PAGEBUILDERCK'));
|
||||
|
||||
// For new records, check the create permission.
|
||||
if ($isNew && $user->authorise('core.create', 'com_pagebuilderck'))
|
||||
{
|
||||
JToolbarHelper::apply('page.apply');
|
||||
JToolbarHelper::save('page.save');
|
||||
JToolbarHelper::cancel('page.cancel');
|
||||
} else
|
||||
{
|
||||
// Can't save the record if it's checked out.
|
||||
if (!$checkedOut)
|
||||
{
|
||||
// Since it's an existing record, check the edit permission, or fall back to edit own if the owner.
|
||||
if (CKFof::userCan('core.edit') || (CKFof::userCan('core.edit.own') && $this->item->created_by == $userId))
|
||||
{
|
||||
JToolbarHelper::apply('page.apply');
|
||||
JToolbarHelper::save('page.save');
|
||||
JToolbarHelper::custom('page.restore', 'archive', 'archive', 'CK_RESTORE', false);
|
||||
}
|
||||
}
|
||||
|
||||
JToolbarHelper::cancel('page.cancel', 'JTOOLBAR_CLOSE');
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user