mirror of
https://github.com/e107inc/e107.git
synced 2025-08-01 20:30:39 +02:00
Featurebox work and other fixes
This commit is contained in:
@@ -1744,7 +1744,10 @@ class e107
|
|||||||
$obj = new $class_name;
|
$obj = new $class_name;
|
||||||
if(method_exists($obj, $method_name))
|
if(method_exists($obj, $method_name))
|
||||||
{
|
{
|
||||||
$mes->debug('Executing <strong>'.$class_name.' :: '.$method_name.'()</strong>');
|
if(E107_DBG_INCLUDES)
|
||||||
|
{
|
||||||
|
$mes->debug('Executing <strong>'.$class_name.' :: '.$method_name.'()</strong>');
|
||||||
|
}
|
||||||
return call_user_func(array($obj, $method_name),$param);
|
return call_user_func(array($obj, $method_name),$param);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@@ -2213,6 +2213,17 @@ class e_form
|
|||||||
}
|
}
|
||||||
$attributes['writeParms']['raw'] = true;
|
$attributes['writeParms']['raw'] = true;
|
||||||
$tmp = $this->renderElement($field, '', $attributes);
|
$tmp = $this->renderElement($field, '', $attributes);
|
||||||
|
|
||||||
|
// Inline Editing. //FIXME!
|
||||||
|
if(!vartrue($attributes['noedit']) && vartrue($parms['editable']) && !vartrue($parms['link'])) // avoid bad markup, better solution coming up
|
||||||
|
{
|
||||||
|
$mode = preg_replace('/[^\w]/', '', vartrue($_GET['mode'], ''));
|
||||||
|
$source = str_replace('"',"'",json_encode($wparms));
|
||||||
|
$value = "<a class='e-tip e-editable editable-click' data-name='".$field."' data-source=\"".$source."\" title=\"".LAN_EDIT." ".$attributes['title']."\" data-type='select' data-pk='".$id."' data-url='".e_SELF."?mode=&action=inline&id={$id}&ajax_used=1' href='#'>".$value."</a>";
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// $value = $pre.vartrue($tmp[$value]).$post; // FIXME "Fatal error: Only variables can be passed by reference" featurebox list page.
|
// $value = $pre.vartrue($tmp[$value]).$post; // FIXME "Fatal error: Only variables can be passed by reference" featurebox list page.
|
||||||
break;
|
break;
|
||||||
|
@@ -29,6 +29,8 @@ class e_jslib
|
|||||||
public function renderHeader($where = 'front', $return = false)
|
public function renderHeader($where = 'front', $return = false)
|
||||||
{
|
{
|
||||||
$ret = '';
|
$ret = '';
|
||||||
|
|
||||||
|
/* DEPRECATED
|
||||||
$ret .= "
|
$ret .= "
|
||||||
<script type=\"text/javascript\">
|
<script type=\"text/javascript\">
|
||||||
var e107Path = {
|
var e107Path = {
|
||||||
@@ -47,6 +49,7 @@ class e_jslib
|
|||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
";
|
";
|
||||||
|
*/
|
||||||
// FIXED: convert e107.js.php to pure e107.js file
|
// FIXED: convert e107.js.php to pure e107.js file
|
||||||
// FIXED: 'e_jslib_browser_cache' used by js_manager - add it together with all new prefs (JS management tab, Site preferences area)
|
// FIXED: 'e_jslib_browser_cache' used by js_manager - add it together with all new prefs (JS management tab, Site preferences area)
|
||||||
// FIXED: option to use external sources (e.g. google) even if JS is combined (script tags for external sources)
|
// FIXED: option to use external sources (e.g. google) even if JS is combined (script tags for external sources)
|
||||||
|
@@ -43,11 +43,15 @@ class e_media
|
|||||||
* @param string $fmask [optional] filetypes eg. .jpg|.gif IMAGES is the default mask.
|
* @param string $fmask [optional] filetypes eg. .jpg|.gif IMAGES is the default mask.
|
||||||
* @return e_media
|
* @return e_media
|
||||||
*/
|
*/
|
||||||
public function import($cat='',$epath,$fmask='')
|
public function import($cat='',$epath,$fmask='',$options=array())
|
||||||
{
|
{
|
||||||
if(!vartrue($cat)){ return $this;}
|
if(!vartrue($cat)){ return $this;}
|
||||||
|
|
||||||
|
if(is_string($options))
|
||||||
|
{
|
||||||
|
parse_str($options,$options);
|
||||||
|
}
|
||||||
|
|
||||||
if(!is_readable($epath))
|
if(!is_readable($epath))
|
||||||
{
|
{
|
||||||
return $this;
|
return $this;
|
||||||
@@ -72,6 +76,18 @@ class e_media
|
|||||||
$count = 0;
|
$count = 0;
|
||||||
foreach($img_array as $f)
|
foreach($img_array as $f)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
if(vartrue($options['min-width']) && ($f['img-width'] < $options['min-width']))
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(vartrue($options['min-size']) && ($f['fsize'] < $options['min-size']))
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
$fullpath = $tp->createConstants($f['path'].$f['fname'],1);
|
$fullpath = $tp->createConstants($f['path'].$f['fname'],1);
|
||||||
// echo "<br />cat=".$cat;
|
// echo "<br />cat=".$cat;
|
||||||
$insert = array(
|
$insert = array(
|
||||||
|
@@ -597,8 +597,10 @@ class themeHandler
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if($mode == 'choose')
|
||||||
|
{
|
||||||
|
echo "<div class='left'>".$frm->checkbox("install-demo-content",1)." Install Demo Content if available.</div>";
|
||||||
|
}
|
||||||
echo "</form>\n</div>\n";
|
echo "</form>\n</div>\n";
|
||||||
|
|
||||||
|
|
||||||
@@ -1329,7 +1331,7 @@ class themeHandler
|
|||||||
$core->set('sitetheme_deflayout', $deflayout);
|
$core->set('sitetheme_deflayout', $deflayout);
|
||||||
$core->set('sitetheme_custompages', $customPages);
|
$core->set('sitetheme_custompages', $customPages);
|
||||||
$core->set('sitetheme_version', $version);
|
$core->set('sitetheme_version', $version);
|
||||||
$core->set('sitetheme_releaseUrl', $this->themeArray[$name]['releaseUrl']);
|
// $core->set('sitetheme_releaseUrl', $this->themeArray[$name]['releaseUrl']);
|
||||||
|
|
||||||
$sql->db_Delete("menus", "menu_layout !='' ");
|
$sql->db_Delete("menus", "menu_layout !='' ");
|
||||||
|
|
||||||
@@ -1344,6 +1346,17 @@ class themeHandler
|
|||||||
|
|
||||||
$med = e107::getMedia();
|
$med = e107::getMedia();
|
||||||
$med->import('_common_image', e_THEME.$name, "^.*?logo.*?(\.png|\.jpeg|\.jpg|\.JPG|\.GIF|\.PNG)$");
|
$med->import('_common_image', e_THEME.$name, "^.*?logo.*?(\.png|\.jpeg|\.jpg|\.JPG|\.GIF|\.PNG)$");
|
||||||
|
$med->import('_common_image', e_THEME.$name, '', 'min-size=20000');
|
||||||
|
|
||||||
|
$XMLImportfile = e_THEME.$name."/install/install.xml";
|
||||||
|
|
||||||
|
if(vartrue($_POST['install-demo-content']) && is_readable($XMLImportfile))
|
||||||
|
{
|
||||||
|
e107::getXml()->e107Import($XMLImportfile, 'replace', true, false); // Overwrite specific core pref and tables entries.
|
||||||
|
$mes->addDebug('Theme Prefs/Tables (install.xml) imported.');
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$this->theme_adminlog('01', $name.', style.css');
|
$this->theme_adminlog('01', $name.', style.css');
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
@@ -69,8 +69,8 @@ class fb_category_ui extends e_admin_ui
|
|||||||
'checkboxes' => array('title'=> '', 'type' => null, 'width' =>'5%', 'forced'=> TRUE, 'thclass'=>'center', 'class'=>'center first'),
|
'checkboxes' => array('title'=> '', 'type' => null, 'width' =>'5%', 'forced'=> TRUE, 'thclass'=>'center', 'class'=>'center first'),
|
||||||
'fb_category_id' => array('title'=> LAN_ID, 'type' => 'number', 'data' => 'int', 'width' =>'5%', 'forced'=> TRUE),
|
'fb_category_id' => array('title'=> LAN_ID, 'type' => 'number', 'data' => 'int', 'width' =>'5%', 'forced'=> TRUE),
|
||||||
'fb_category_icon' => array('title'=> LAN_ICON, 'type' => 'icon', 'data' => 'str', 'width' => '5%', 'thclass' => 'center', 'class'=>'center'),
|
'fb_category_icon' => array('title'=> LAN_ICON, 'type' => 'icon', 'data' => 'str', 'width' => '5%', 'thclass' => 'center', 'class'=>'center'),
|
||||||
'fb_category_title' => array('title'=> LAN_TITLE, 'type' => 'text', 'data' => 'str', 'inline'=>true, 'width' => 'auto', 'validate' => 'str', 'rule' => '1-200', 'error' => 'String between 1-200 characters expected', 'help' => 'up to 200 characters', 'thclass' => 'left'),
|
'fb_category_title' => array('title'=> LAN_TITLE, 'type' => 'text', 'data' => 'str', 'inline'=>true, 'width' => 'auto', 'help' => 'up to 200 characters', 'thclass' => 'left'),
|
||||||
'fb_category_template' => array('title'=> 'Category template', 'type' => 'layouts', 'data' => 'str', 'width' => 'auto', 'thclass' => 'left', 'writeParms' => 'plugin=featurebox&id=featurebox_category&merge=1', 'filter' => true),
|
'fb_category_template' => array('title'=> 'Category template', 'type' => 'layouts', 'inline'=>true, 'data' => 'str', 'width' => 'auto', 'thclass' => 'left', 'writeParms' => 'plugin=featurebox&id=featurebox_category&merge=1', 'filter' => true),
|
||||||
'fb_category_random' => array('title'=> 'Random', 'type' => 'boolean', 'data' => 'int', 'width' => '5%', 'thclass' => 'center', 'class' => 'center', 'batch' => true, 'filter' => true),
|
'fb_category_random' => array('title'=> 'Random', 'type' => 'boolean', 'data' => 'int', 'width' => '5%', 'thclass' => 'center', 'class' => 'center', 'batch' => true, 'filter' => true),
|
||||||
'fb_category_class' => array('title'=> LAN_VISIBILITY, 'type' => 'userclass', 'data' => 'int', 'inline'=>true, 'width' => 'auto', 'filter' => true, 'batch' => true),
|
'fb_category_class' => array('title'=> LAN_VISIBILITY, 'type' => 'userclass', 'data' => 'int', 'inline'=>true, 'width' => 'auto', 'filter' => true, 'batch' => true),
|
||||||
'fb_category_limit' => array('title'=> 'Limit', 'type' => 'number', 'data' => 'int', 'width' => '5%', 'thclass' => 'left', 'help' => 'number of items to be shown, 0 - show all'),
|
'fb_category_limit' => array('title'=> 'Limit', 'type' => 'number', 'data' => 'int', 'width' => '5%', 'thclass' => 'left', 'help' => 'number of items to be shown, 0 - show all'),
|
||||||
|
@@ -148,6 +148,19 @@ class plugin_featurebox_item extends e_model
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns 'active' for the first-slide. - often used by Bootstrap.
|
||||||
|
*/
|
||||||
|
public function sc_featurebox_active()
|
||||||
|
{
|
||||||
|
$count = $this->getParam('counter', 1);
|
||||||
|
return ($count == 1) ? "active" : "";
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Item counter number (starting from 1)
|
* Item counter number (starting from 1)
|
||||||
|
@@ -1,16 +1,54 @@
|
|||||||
<?php
|
<?php
|
||||||
/*
|
/*
|
||||||
* Copyright (c) e107 Inc 2009 - e107.org, Licensed under GNU GPL (http://www.gnu.org/licenses/gpl.txt)
|
* Copyright (c) e107 Inc 2013 - e107.org, Licensed under GNU GPL (http://www.gnu.org/licenses/gpl.txt)
|
||||||
* $Id$
|
|
||||||
*
|
*
|
||||||
* Featurebox core category templates
|
* Featurebox core category templates
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// TODO - list of all available shortcodes & schortcode parameters
|
// TODO - list of all available shortcodes & schortcode parameters
|
||||||
|
|
||||||
// avoid PHP warnings
|
|
||||||
$FEATUREBOX_CATEGORY_TEMPLATE = array();
|
$FEATUREBOX_CATEGORY_TEMPLATE = array();
|
||||||
|
|
||||||
|
|
||||||
|
// v2.x Default - Bootstrap.
|
||||||
|
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['list_start'] = '
|
||||||
|
<!-- starts carousel -->
|
||||||
|
<div class="row animated fadeInDown">
|
||||||
|
<div class="span12">
|
||||||
|
<div id="myCarousel" class="carousel slide">
|
||||||
|
<!-- carousel items -->
|
||||||
|
<div class="carousel-inner">
|
||||||
|
';
|
||||||
|
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['list_end'] = '
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Carousel nav -->
|
||||||
|
<a class="carousel-control left" href="#myCarousel" data-slide="prev">‹</a>
|
||||||
|
<a class="carousel-control right" href="#myCarousel" data-slide="next">›</a>
|
||||||
|
|
||||||
|
</div><!-- end myCarousel -->
|
||||||
|
</div><!-- end span12 -->
|
||||||
|
</div><!-- end row -->
|
||||||
|
|
||||||
|
<!-- end carousel -->
|
||||||
|
';
|
||||||
|
|
||||||
|
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['col_start'] = '';
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['col_end'] = '';
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['item_start'] = '';
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['item_end'] = '';
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['item_separator'] = '';
|
||||||
|
$FEATUREBOX_CATEGORY_TEMPLATE['bootstrap_carousel']['item_empty'] = '';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// GENERIC template avoid PHP warnings
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Default Template
|
* Default Template
|
||||||
* Example call: {FEATUREBOX} or {FEATUREBOX|default}
|
* Example call: {FEATUREBOX} or {FEATUREBOX|default}
|
||||||
@@ -34,9 +72,10 @@ $FEATUREBOX_CATEGORY_TEMPLATE['default']['item_start'] = '';
|
|||||||
$FEATUREBOX_CATEGORY_TEMPLATE['default']['item_end'] = '';
|
$FEATUREBOX_CATEGORY_TEMPLATE['default']['item_end'] = '';
|
||||||
$FEATUREBOX_CATEGORY_TEMPLATE['default']['item_separator'] = '<div class="clear"><!-- --></div>';
|
$FEATUREBOX_CATEGORY_TEMPLATE['default']['item_separator'] = '<div class="clear"><!-- --></div>';
|
||||||
|
|
||||||
// empty item - used with col templates, no shortcodes just basic markup
|
|
||||||
$FEATUREBOX_CATEGORY_TEMPLATE['default']['item_empty'] = '';
|
$FEATUREBOX_CATEGORY_TEMPLATE['default']['item_empty'] = '';
|
||||||
|
|
||||||
|
|
||||||
// no dynamic load support
|
// no dynamic load support
|
||||||
//$FEATUREBOX_CATEGORY_TEMPLATE['default']['nav_start'] = '';
|
//$FEATUREBOX_CATEGORY_TEMPLATE['default']['nav_start'] = '';
|
||||||
//$FEATUREBOX_CATEGORY_TEMPLATE['default']['nav_item'] = '';
|
//$FEATUREBOX_CATEGORY_TEMPLATE['default']['nav_item'] = '';
|
||||||
@@ -48,6 +87,9 @@ $FEATUREBOX_CATEGORY_TEMPLATE['default']['item_empty'] = '';
|
|||||||
// inline JS, without <script> tags
|
// inline JS, without <script> tags
|
||||||
//$FEATUREBOX_CATEGORY_TEMPLATE['default']['js_inline'] = '';
|
//$FEATUREBOX_CATEGORY_TEMPLATE['default']['js_inline'] = '';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Dynamic Template
|
* Dynamic Template
|
||||||
* Example call: {FEATUREBOX|dynamic}
|
* Example call: {FEATUREBOX|dynamic}
|
||||||
@@ -247,11 +289,12 @@ $FEATUREBOX_CATEGORY_TEMPLATE['camera']['js_type'] = 'jquery';
|
|||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
$FEATUREBOX_CATEGORY_INFO = array(
|
$FEATUREBOX_CATEGORY_INFO = array(
|
||||||
'tabs' => array('title' => 'Tabs (jquery)' , 'description' => 'Tabbed Feature box items utlizing jQuery UI'),
|
'bootstrap_carousel' => array('title' => 'Bootstrap Carousel', 'description' => "Bootstrap's Hero slider"),
|
||||||
'camera' => array('title' => 'Image-Slider (jquery)' , 'description' => 'Image transitions using the "Camera" jquery plugin'),
|
'tabs' => array('title' => 'Tabs (jquery UI)' , 'description' => 'Tabbed Feature box items utlizing jQuery UI'),
|
||||||
'accordion' => array('title' => 'Accordion (jquery)' , 'description' => 'Accordion utilizing jQuery UI'),
|
'camera' => array('title' => 'Image-Slider (jquery)' , 'description' => 'Image transitions using the "Camera" jquery plugin'),
|
||||||
'default' => array('title' => 'Default (prototype.js)', 'description' => 'Flat - show by category limit'),
|
'accordion' => array('title' => 'Accordion (jquery)' , 'description' => 'Accordion utilizing jQuery UI'),
|
||||||
'dynamic' => array('title' => 'Dynamic (prototype.js)', 'description' => 'Load items on click (AJAX)'),
|
'default' => array('title' => 'Default (prototype.js)', 'description' => 'Flat - show by category limit'),
|
||||||
'tabs-proto' => array('title' => 'Tabs (prototype.js)' , 'description' => 'Tabbed Feature box items')
|
'dynamic' => array('title' => 'Dynamic (prototype.js)', 'description' => 'Load items on click (AJAX)'),
|
||||||
|
'tabs-proto' => array('title' => 'Tabs (prototype.js)' , 'description' => 'Tabbed Feature box items')
|
||||||
);
|
);
|
||||||
?>
|
?>
|
@@ -8,6 +8,67 @@
|
|||||||
|
|
||||||
global $sc_style;
|
global $sc_style;
|
||||||
|
|
||||||
|
|
||||||
|
// e107 v2.x Defaults.
|
||||||
|
|
||||||
|
$FEATUREBOX_TEMPLATE['bootstrap_carousel_left'] = '
|
||||||
|
<!-- slide -->
|
||||||
|
<div class="{FEATUREBOX_ACTIVE} item slide{FEATUREBOX_COUNTER}">
|
||||||
|
<div class="row">
|
||||||
|
<div class="span6">
|
||||||
|
{FEATUREBOX_IMAGE}
|
||||||
|
</div>
|
||||||
|
<div class="span4">
|
||||||
|
<h1>
|
||||||
|
{FEATUREBOX_TITLE}
|
||||||
|
</h1>
|
||||||
|
{FEATUREBOX_TEXT}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- -->
|
||||||
|
|
||||||
|
';
|
||||||
|
|
||||||
|
$FEATUREBOX_TEMPLATE['bootstrap_carousel_right'] = '
|
||||||
|
<div class="{FEATUREBOX_ACTIVE} item slide{FEATUREBOX_COUNTER}">
|
||||||
|
<div class="row">
|
||||||
|
<div class="span4 animated fadeInUpBig">
|
||||||
|
<h1>{FEATUREBOX_TITLE}</h1>
|
||||||
|
{FEATUREBOX_TEXT}
|
||||||
|
</div>
|
||||||
|
<div class="span6 animated fadeInDownBig">
|
||||||
|
{FEATUREBOX_IMAGE}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
';
|
||||||
|
|
||||||
|
|
||||||
|
$FEATUREBOX_TEMPLATE['bootstrap_carousel_image'] = '
|
||||||
|
<div class="item slide3 animated fadeInUpBig">
|
||||||
|
{FEATUREBOX_IMAGE}
|
||||||
|
</div>
|
||||||
|
';
|
||||||
|
|
||||||
|
|
||||||
|
// ----------------------------
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$sc_style['FEATUREBOX_IMAGE|image_left']['pre'] = '<img class="f-left" src="';
|
||||||
|
$sc_style['FEATUREBOX_IMAGE|image_left']['post'] = '" alt="" />';
|
||||||
|
|
||||||
$FEATUREBOX_TEMPLATE['default'] = '<!-- Feature box Item -->
|
$FEATUREBOX_TEMPLATE['default'] = '<!-- Feature box Item -->
|
||||||
<div class="featurebox-item" >
|
<div class="featurebox-item" >
|
||||||
<h3>{FEATUREBOX_TITLE|default}</h3>
|
<h3>{FEATUREBOX_TITLE|default}</h3>
|
||||||
@@ -16,8 +77,7 @@ $FEATUREBOX_TEMPLATE['default'] = '<!-- Feature box Item -->
|
|||||||
';
|
';
|
||||||
|
|
||||||
|
|
||||||
$sc_style['FEATUREBOX_IMAGE|image_left']['pre'] = '<img class="f-left" src="';
|
|
||||||
$sc_style['FEATUREBOX_IMAGE|image_left']['post'] = '" alt="" />';
|
|
||||||
$FEATUREBOX_TEMPLATE['image_left'] = '
|
$FEATUREBOX_TEMPLATE['image_left'] = '
|
||||||
<div class="featurebox-item">
|
<div class="featurebox-item">
|
||||||
{FEATUREBOX_IMAGE|image_left=src}<h3>{FEATUREBOX_TITLE|image_left}</h3>{FEATUREBOX_TEXT|image_left}
|
{FEATUREBOX_IMAGE|image_left=src}<h3>{FEATUREBOX_TITLE|image_left}</h3>{FEATUREBOX_TEXT|image_left}
|
||||||
@@ -77,12 +137,19 @@ $FEATUREBOX_TEMPLATE['tabs'] = '
|
|||||||
|
|
||||||
|
|
||||||
$FEATUREBOX_INFO = array(
|
$FEATUREBOX_INFO = array(
|
||||||
'default' => array('title' => 'Default (core)', 'description' => 'Title and description - no image'),
|
|
||||||
'image_right' => array('title' => 'Right image (core)', 'description' => 'Right floated image'),
|
'bootstrap_carousel_default' => array('title' => 'Bootstrap', 'description' => 'Title and Description'),
|
||||||
'image_left' => array('title' => 'Left image (core)' , 'description' => 'Left floated image'),
|
'bootstrap_carousel_image' => array('title' => 'Bootstrap Carousel (Image-Only)', 'description' => 'Image Only'),
|
||||||
'camera' => array('title' => 'Camera item', 'description' => 'For use with the "camera" category'),
|
'bootstrap_carousel_left' => array('title' => 'Bootstrap Carousel (Image-left)', 'description' => 'Image aligned left with title and text on the right'),
|
||||||
'camera_caption' => array('title' => 'Camera item with caption', 'description' => 'For use with the "camera" category'),
|
'bootstrap_carousel_right' => array('title' => 'Bootstrap Carousel (Image-right)', 'description' => 'Image aligned right with title and text on the left'),
|
||||||
'accordion' => array('title' => 'Accordion Item', 'description' => 'For use with accordion'),
|
|
||||||
'tabs' => array('title' => 'Tab Item', 'description' => 'For use with tabs')
|
'default' => array('title' => 'Generic', 'description' => 'Title and description - no image'),
|
||||||
|
'image_left' => array('title' => 'Generic - (Image-left)' , 'description' => 'Left floated image'),
|
||||||
|
'image_right' => array('title' => 'Generic - (Image-right)', 'description' => 'Right floated image'),
|
||||||
|
|
||||||
|
'camera' => array('title' => 'Camera item', 'description' => 'For use with the "camera" category'),
|
||||||
|
'camera_caption' => array('title' => 'Camera item with caption', 'description' => 'For use with the "camera" category'),
|
||||||
|
'accordion' => array('title' => 'Accordion Item', 'description' => 'For use with accordion'),
|
||||||
|
'tabs' => array('title' => 'Tab Item', 'description' => 'For use with tabs')
|
||||||
);
|
);
|
||||||
?>
|
?>
|
@@ -18,6 +18,8 @@ e107::css('inline',"
|
|||||||
.area { border-left: 1px solid rgb(221, 221, 221); border-bottom: 1px solid rgb(221, 221, 221);
|
.area { border-left: 1px solid rgb(221, 221, 221); border-bottom: 1px solid rgb(221, 221, 221);
|
||||||
background-color: rgb(246, 246, 246); margin-top:-1px
|
background-color: rgb(246, 246, 246); margin-top:-1px
|
||||||
}
|
}
|
||||||
|
span.badge { cursor: pointer }
|
||||||
|
span.label { cursor: pointer }
|
||||||
|
|
||||||
");
|
");
|
||||||
|
|
||||||
@@ -44,6 +46,16 @@ $(document).ready(function()
|
|||||||
tinyMCEPopup.close();
|
tinyMCEPopup.close();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
$('span.label, span.badge').click(function () {
|
||||||
|
var cls = $(this).attr('class');
|
||||||
|
var html = '<span class=\"' + cls + '\">' + $(this).text() + '</span> ';
|
||||||
|
tinyMCEPopup.editor.execCommand('mceInsertContent', false, html);
|
||||||
|
tinyMCEPopup.close();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$('#e-cancel').click(function () {
|
$('#e-cancel').click(function () {
|
||||||
|
|
||||||
tinyMCEPopup.close();
|
tinyMCEPopup.close();
|
||||||
@@ -57,6 +69,10 @@ $(document).ready(function()
|
|||||||
|
|
||||||
class e_bootstrap
|
class e_bootstrap
|
||||||
{
|
{
|
||||||
|
|
||||||
|
private $styleClasses = array(''=>'Default', 'primary'=>"Primary", 'success'=>"Success", 'info'=>"Info", 'warning'=>"Warning",'danger'=>"Danger",'inverse'=>"Inverse");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
function init()
|
function init()
|
||||||
{
|
{
|
||||||
@@ -66,14 +82,14 @@ class e_bootstrap
|
|||||||
<ul class="nav nav-tabs">
|
<ul class="nav nav-tabs">
|
||||||
<li class="active" ><a href="#mbuttons" data-toggle="tab">Buttons</a></li>';
|
<li class="active" ><a href="#mbuttons" data-toggle="tab">Buttons</a></li>';
|
||||||
|
|
||||||
// $text .= '<li><a href="#mprofile" data-toggle="tab">Profile</a></li>';
|
$text .= '<li><a href="#badges" data-toggle="tab">Labels & Badges</a></li>';
|
||||||
|
|
||||||
$text .= '</ul>';
|
$text .= '</ul>';
|
||||||
|
|
||||||
$text .= '<div class="tab-content">
|
$text .= '<div class="tab-content">
|
||||||
<div class="tab-pane active left" id="mbuttons">'.$this->buttonForm().'</div>';
|
<div class="tab-pane active left" id="mbuttons">'.$this->buttonForm().'</div>';
|
||||||
|
|
||||||
// $text = '<div class="tab-pane" id="mprofile">Wow</div>';
|
$text .= '<div class="tab-pane left" id="badges">'.$this->badgeForm().'</div>';
|
||||||
|
|
||||||
$text .= '</div>';
|
$text .= '</div>';
|
||||||
|
|
||||||
@@ -90,8 +106,9 @@ class e_bootstrap
|
|||||||
{
|
{
|
||||||
$frm = e107::getForm();
|
$frm = e107::getForm();
|
||||||
|
|
||||||
$buttonTypes = array(''=>'Default', 'primary'=>"Primary", 'success'=>"Success", 'info'=>"Info", 'warning'=>"Warning",'danger'=>"Danger",'inverse'=>"Inverse");
|
|
||||||
$buttonSizes = array(''=>'Default', 'btn-mini'=>"Mini", 'btn-small'=>"Small", 'btn-large' => "Large");
|
$buttonSizes = array(''=>'Default', 'btn-mini'=>"Mini", 'btn-small'=>"Small", 'btn-large' => "Large");
|
||||||
|
|
||||||
|
$buttonTypes = $this->styleClasses;
|
||||||
|
|
||||||
$butSelect = "";
|
$butSelect = "";
|
||||||
$butSelect .= "<div class='form-inline' style='padding:5px'>";
|
$butSelect .= "<div class='form-inline' style='padding:5px'>";
|
||||||
@@ -145,6 +162,36 @@ class e_bootstrap
|
|||||||
return $text;
|
return $text;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function badgeForm()
|
||||||
|
{
|
||||||
|
unset($this->styleClasses['primary']);
|
||||||
|
|
||||||
|
foreach($this->styleClasses as $key=>$type)
|
||||||
|
{
|
||||||
|
$classLabel = ($key != '') ? " label-".$key : "";
|
||||||
|
$classBadge = ($key != '') ? " badge-".$key : "";
|
||||||
|
|
||||||
|
$text .= '<div style="padding:10px"><span class="label'.$classLabel.'">'.$type.'</span> ';
|
||||||
|
$text .= '<span class="badge'.$classBadge.'">'.$type.'</span>';
|
||||||
|
$text .= "</div>";
|
||||||
|
}
|
||||||
|
|
||||||
|
return $text;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@@ -321,9 +321,9 @@ unset($uclist, $bcache);
|
|||||||
if(!deftrue('e_POWEREDBY_DISABLE'))
|
if(!deftrue('e_POWEREDBY_DISABLE'))
|
||||||
{
|
{
|
||||||
// No IDs or Classes - hinder js disable.
|
// No IDs or Classes - hinder js disable.
|
||||||
echo "<div style='margin:20px; text-align:center;position: display:block; relative; bottom: 90px; z-index:30000; opacity:1.0; color: silver'>Proudly powered by <a style='color:silver' href='http://e107.org/' title='e107 Content Management System'>e107</a></div>";
|
echo "<div style='margin:20px; text-align:center;position: display:block; position: relative; bottom: 90px; z-index:30000; opacity:1.0; color: silver'>Proudly powered by <a style='color:silver' href='http://e107.org/' title='e107 Content Management System'>e107</a></div>";
|
||||||
}
|
}
|
||||||
echo "</body></html>";
|
echo "\n</body>\n</html>";
|
||||||
|
|
||||||
//
|
//
|
||||||
// I Send the buffered page data, along with appropriate headers
|
// I Send the buffered page data, along with appropriate headers
|
||||||
|
Reference in New Issue
Block a user