1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-18 12:21:45 +02:00

Merging with upstream

This commit is contained in:
Deltik
2013-05-07 08:15:48 -05:00
21 changed files with 360 additions and 226 deletions

View File

@@ -1087,6 +1087,10 @@ if(e_ADMIN_AREA)
else else
{ {
require_once (THEME.'theme.php'); require_once (THEME.'theme.php');
if(isset($SC_WRAPPER))
{
e107::scStyle($SC_WRAPPER);
}
} }

View File

@@ -1,6 +1,16 @@
User-agent: * User-agent: *
Disallow: /sitedown.php Disallow: /sitedown.php
Disallow: /cron.php
Disallow: /fpw.php
Disallow: /membersonly.php
Disallow: /e107_admin/ Disallow: /e107_admin/
Disallow: /e107_handlers/ Disallow: /e107_core/
Disallow: /e107_docs/
Disallow: /e107_files/cache/ Disallow: /e107_files/cache/
Disallow: /e107_files/public/avatars/ Disallow: /e107_files/public/avatars/
Disallow: /e107_handlers/
Disallow: /e107_languages/
Disallow: /e107_media/
Disallow: /e107_system/
Disallow: /e107_themes/
Disallow: /e107_web/

View File

@@ -668,7 +668,7 @@ class media_admin_ui extends e_admin_ui
'media_dimensions' => array('title'=> "Dimensions", 'type' => 'text', 'data'=> 'str', 'width' => '5%', 'readonly'=>TRUE, 'class'=>'nowrap','noedit'=>TRUE), 'media_dimensions' => array('title'=> "Dimensions", 'type' => 'text', 'data'=> 'str', 'width' => '5%', 'readonly'=>TRUE, 'class'=>'nowrap','noedit'=>TRUE),
'media_userclass' => array('title'=> LAN_USERCLASS, 'type' => 'userclass', 'data'=> 'str', 'inline'=>true, 'width' => '10%', 'thclass' => 'center','filter'=>TRUE,'batch'=>TRUE ), 'media_userclass' => array('title'=> LAN_USERCLASS, 'type' => 'userclass', 'data'=> 'str', 'inline'=>true, 'width' => '10%', 'thclass' => 'center','filter'=>TRUE,'batch'=>TRUE ),
'media_tags' => array('title'=> "Tags/Keywords", 'type' => 'tags', 'data'=> 'str', 'width' => '10%', 'filter'=>TRUE,'batch'=>TRUE ), 'media_tags' => array('title'=> "Tags/Keywords", 'type' => 'tags', 'data'=> 'str', 'width' => '10%', 'filter'=>TRUE,'batch'=>TRUE ),
'media_usedby' => array('title'=> '', 'type' => 'text', 'data'=> 'text', 'width' => 'auto', 'thclass' => 'center', 'class'=>'center', 'nolist'=>true, 'readonly'=>TRUE ), 'media_usedby' => array('title'=> 'Used by', 'type' => '', 'data'=> 'text', 'width' => 'auto', 'thclass' => 'center', 'class'=>'center', 'nolist'=>true, 'readonly'=>TRUE ),
'options' => array('title'=> LAN_OPTIONS, 'type' => 'method', 'data'=> null, 'forced'=>TRUE, 'width' => '10%', 'thclass' => 'center last', 'class' => 'center', 'batch'=>true, 'noedit'=>true) 'options' => array('title'=> LAN_OPTIONS, 'type' => 'method', 'data'=> null, 'forced'=>TRUE, 'width' => '10%', 'thclass' => 'center last', 'class' => 'center', 'batch'=>true, 'noedit'=>true)
); );

View File

@@ -492,7 +492,6 @@ class links_model_admin_tree extends e_admin_tree_model
{ {
$search[$model->get('link_parent')][$id] = $model; $search[$model->get('link_parent')][$id] = $model;
} }
asort($search); asort($search);
$this->_tree_order($this->current_id, $search, $this->$var, 0, $modified); $this->_tree_order($this->current_id, $search, $this->$var, 0, $modified);
} }
@@ -522,11 +521,27 @@ class links_model_admin_tree extends e_admin_tree_model
$src[$id] = $model; $src[$id] = $model;
if($modified) if($modified)
{ {
$model->set('link_name', $level_image.$model->get('link_name')); $model->set('link_name', $level_image.$this->bcClean($model->get('link_name')));
} }
$this->_tree_order($id, $search, $src, $level + 1, $modified); $this->_tree_order($id, $search, $src, $level + 1, $modified);
} }
} }
function bcClean($link_name)
{
if(substr($link_name, 0,8) == 'submenu.') // BC Fix.
{
list($tmp,$tmp2,$link) = explode('.', $link_name, 3);
}
else
{
$link = $link_name;
}
return $link;
}
} }

View File

@@ -27,11 +27,10 @@ if(e_AJAX_REQUEST && isset($_GET['src'])) // Ajax
$localfile = md5($remotefile.time()).".zip"; $localfile = md5($remotefile.time()).".zip";
$status = "Downloading..."; $status = "Downloading...";
// e107::getFile()->getRemoteFile($remotefile,$localfile); $fl = e107::getFile();
//$fl->setAuthKey('username','password');
e107::getFile()->download($remotefile,'plugin'); $fl->download($remotefile,'plugin');
exit; exit;
/* /*
@@ -265,14 +264,13 @@ class pluginManager{
"plugin_icon" => array("title" => EPL_ADLAN_82, "type"=>"icon", "width" => "5%", "thclass" => "middle center",'class'=>'center', "url" => ""), "plugin_icon" => array("title" => EPL_ADLAN_82, "type"=>"icon", "width" => "5%", "thclass" => "middle center",'class'=>'center', "url" => ""),
"plugin_name" => array("title" => EPL_ADLAN_10, 'forced'=>true, "type"=>"text", "width" => "auto", 'class'=>'left', "thclass" => "middle", "url" => ""), "plugin_name" => array("title" => EPL_ADLAN_10, 'forced'=>true, "type"=>"text", "width" => "auto", 'class'=>'left', "thclass" => "middle", "url" => ""),
"plugin_version" => array("title" => EPL_ADLAN_11, "type"=>"numeric", "width" => "5%", "thclass" => "middle", "url" => ""), "plugin_version" => array("title" => EPL_ADLAN_11, "type"=>"numeric", "width" => "5%", "thclass" => "middle", "url" => ""),
"plugin_date" => array("title" => "Released ", "type"=>"text", "width" => "10%", "thclass" => "middle"), "plugin_date" => array("title" => "Released ", "type"=>"text", "width" => "8%", "thclass" => "middle"),
"plugin_folder" => array("title" => EPL_ADLAN_64, "type"=>"text", "width" => "10%", "thclass" => "middle"), "plugin_folder" => array("title" => EPL_ADLAN_64, "type"=>"text", "width" => "10%", "thclass" => "middle"),
"plugin_category" => array("title" => LAN_CATEGORY, "type"=>"text", "width" => "auto", "thclass" => "middle"), "plugin_category" => array("title" => LAN_CATEGORY, "type"=>"text", "width" => "auto", "thclass" => "middle"),
"plugin_author" => array("title" => EPL_ADLAN_12, "type"=>"text", "width" => "10%", "thclass" => "middle"), "plugin_author" => array("title" => EPL_ADLAN_12, "type"=>"text", "width" => "10%", "thclass" => "middle"),
// "plugin_website" => array("title" => EPL_WEBSITE, "type"=>"method", "width" => "5%", "thclass" => "middle center"), "plugin_price" => array("title" => "Price", 'nolist'=>true, "forced"=>true, "type"=>"text", "width" => "5%", "thclass" => "left"),
"plugin_compatible" => array("title" => EPL_ADLAN_13, "type"=>"text", "width" => "5%", "thclass" => "middle"), "plugin_compatible" => array("title" => EPL_ADLAN_13, "type"=>"text", "width" => "5%", "thclass" => "middle"),
"plugin_description" => array("title" => EPL_ADLAN_14, "type"=>"bbarea", "width" => "30%", "thclass" => "middle center", 'readParms' => 'expand=1&truncate=180&bb=1'), "plugin_description" => array("title" => EPL_ADLAN_14, "type"=>"bbarea", "width" => "30%", "thclass" => "middle center", 'readParms' => 'expand=1&truncate=180&bb=1'),
"plugin_compliant" => array("title" => EPL_ADLAN_81, "type"=>"text", "width" => "5%", "thclass" => "middle center", "url" => ""), "plugin_compliant" => array("title" => EPL_ADLAN_81, "type"=>"text", "width" => "5%", "thclass" => "middle center", "url" => ""),
// "plugin_release" => array("title" => EPL_ADLAN_81, "type"=>"text", "width" => "5%", "thclass" => "middle center", "url" => ""), // "plugin_release" => array("title" => EPL_ADLAN_81, "type"=>"text", "width" => "5%", "thclass" => "middle center", "url" => ""),
@@ -298,6 +296,11 @@ class pluginManager{
$this->action = $_GET['mode']; $this->action = $_GET['mode'];
} }
if($this->action == 'online')
{
$this->fields["plugin_price"]['nolist'] = false; // = array("title" => "Price", "forced"=>true, "type"=>"text", "width" => "5%", "thclass" => "middle center");
}
$keys = array_keys($this -> titlearray); $keys = array_keys($this -> titlearray);
$this->pagetitle = (in_array($this->action,$keys)) ? $this -> titlearray[$this->action] : $this -> titlearray['installed']; $this->pagetitle = (in_array($this->action,$keys)) ? $this -> titlearray[$this->action] : $this -> titlearray['installed'];
@@ -343,9 +346,17 @@ class pluginManager{
$user_pref['admin_pluginmanager_columns'] = false; $user_pref['admin_pluginmanager_columns'] = false;
$this -> fieldpref = (vartrue($user_pref['admin_pluginmanager_columns'])) ? $user_pref['admin_pluginmanager_columns'] : array("plugin_icon","plugin_name","plugin_version","plugin_date","plugin_description","plugin_category","plugin_compatible","plugin_author","plugin_website","plugin_notes"); $this -> fieldpref = (vartrue($user_pref['admin_pluginmanager_columns'])) ? $user_pref['admin_pluginmanager_columns'] : array("plugin_icon","plugin_name","plugin_version","plugin_date","plugin_description","plugin_category","plugin_compatible","plugin_author","plugin_website","plugin_notes");
foreach($this->fields as $key=>$val)
{
if($val['forced'] == true && substr($key,0,6)=='plugin')
{
$this->fieldpref[] = $key;
}
}
if($this->action == 'avail' || $this->action == 'installed') // Plugin Check is done during upgrade_routine. if($this->action == 'avail' || $this->action == 'installed') // Plugin Check is done during upgrade_routine.
{ {
@@ -465,13 +476,14 @@ class pluginManager{
{ {
$row = $r['@attributes']; $row = $r['@attributes'];
$badge = $this->compatibilityLabel($row['compatibility']);; $badge = $this->compatibilityLabel($row['compatibility']);;
$featured = ($row['featured']== 1) ? " <span class='label label-info'>Featured</span>" : ''; $featured = ($row['featured']== 1) ? " <span class='label label-info'>Featured</span>" : '';
$price = ($row['price'] > 0) ? "<span class='label label-success'>".$row['price']." credits</span>" : "<span class='label label-success'>Free</span>";
$data[] = array( $data[] = array(
'plugin_id' => $c, 'plugin_id' => $c,
'plugin_icon' => vartrue($row['icon'],e_IMAGE."admin_images/plugins_32.png"), 'plugin_icon' => vartrue($row['icon'],e_IMAGE."admin_images/plugins_32.png"),
'plugin_name' => $row['name'].$featured, 'plugin_name' => stripslashes($row['name']).$featured,
'plugin_folder' => $row['folder'], 'plugin_folder' => $row['folder'],
'plugin_date' => vartrue($row['date']), 'plugin_date' => vartrue($row['date']),
'plugin_category' => vartrue($r['category'][0]), 'plugin_category' => vartrue($r['category'][0]),
@@ -482,8 +494,10 @@ class pluginManager{
'plugin_website' => vartrue($row['authorUrl']), 'plugin_website' => vartrue($row['authorUrl']),
'plugin_url' => $row['url'], 'plugin_url' => $row['url'],
'plugin_notes' => '' 'plugin_notes' => '',
); 'plugin_price' => $price
);
$c++; $c++;
} }
@@ -498,7 +512,7 @@ class pluginManager{
$text = " $text = "
<form action='".e_SELF."?".e_QUERY."' id='core-plugin-list-form' method='get'> <form class='form-search' action='".e_SELF."?".e_QUERY."' id='core-plugin-list-form' method='get'>
<div class='e-search'>".$frm->search('srch', $srch, 'go', $filterName, $filterArray, $filterVal).$frm->hidden('mode','online')." <div class='e-search'>".$frm->search('srch', $srch, 'go', $filterName, $filterArray, $filterVal).$frm->hidden('mode','online')."
</div> </div>
</form> </form>

View File

@@ -42,7 +42,7 @@ e107::css("inline","
.admin-theme-options:hover { opacity:0.8; } .admin-theme-options:hover { opacity:0.8; }
.admin-theme-title { font-size: 15px; overflow:hidden; padding-left:5px; white-space:no-wrap; width:200px; position:relative; top:-132px; } .admin-theme-title { line-height: 18px; overflow:hidden; padding-left:5px; white-space:no-wrap; width:200px; position:relative; top:-132px; }
.admin-theme-select {border:1px dotted silver;background-color:#DDDDDD;float:left } .admin-theme-select {border:1px dotted silver;background-color:#DDDDDD;float:left }

View File

@@ -18,5 +18,6 @@ function navigation_shortcode($parm='')
// $data = $nav->collection($category); // $data = $nav->collection($category);
return $nav->render($data, $template); return $nav->render($data, $template);
} }

View File

@@ -625,7 +625,7 @@ if ($e107_popup != 1) {
if(ADMIN) if(ADMIN)
{ {
if(file_exists(e_BASE.'install.php')){ echo "<div class='installer'><br /><b>*** ".CORE_LAN4." ***</b><br />".CORE_LAN5."</div><br /><br />"; } if(file_exists(e_BASE.'install.php') || file_exists(e_BASE.'install_.php')){ echo "<div class='installer alert alert-danger alert-block text-center'><b>*** ".CORE_LAN4." ***</b><br />".CORE_LAN5."</div>"; }
} }
// Display Welcome Message when old method activated. // Display Welcome Message when old method activated.

View File

@@ -153,7 +153,7 @@ class e_parse extends e_parser
// text is user-entered (i.e. untrusted)'body' or 'bulk' text (e.g. custom page body, content body) // text is user-entered (i.e. untrusted)'body' or 'bulk' text (e.g. custom page body, content body)
'USER_BODY' => 'USER_BODY' =>
array( array(
'constants'=>'full', 'scripts' => FALSE 'constants'=>'full', 'scripts' => FALSE, 'nostrip'=>FALSE
), ),
// text is 'body' of email or similar - being sent 'off-site' so don't rely on server availability // text is 'body' of email or similar - being sent 'off-site' so don't rely on server availability
'E_BODY' => 'E_BODY' =>
@@ -538,7 +538,7 @@ class e_parse extends e_parser
/** /**
* Check for umatched 'dangerous' HTML tags * Check for umatched 'dangerous' HTML tags
* (these can destroy page layout where users are able to post HTML) * (these can destroy page layout where users are able to post HTML)
* * @DEPRECATED
* @param string $data * @param string $data
* @param string $tagList - if empty, uses default list of input tags. Otherwise a CSV list of tags to check (any type) * @param string $tagList - if empty, uses default list of input tags. Otherwise a CSV list of tags to check (any type)
* *
@@ -597,7 +597,7 @@ class e_parse extends e_parser
/** /**
* XXX TODO Remove this horrible thing which adds junk to a db. * @DEPRECATED XXX TODO Remove this horrible thing which adds junk to a db.
* Checks a string for potentially dangerous HTML tags, including malformed tags * Checks a string for potentially dangerous HTML tags, including malformed tags
* *
*/ */
@@ -666,7 +666,7 @@ class e_parse extends e_parser
} }
// XXX REmove ME.
private function modTag($match) private function modTag($match)
{ {
$ans = ''; $ans = '';
@@ -1342,6 +1342,11 @@ class e_parse extends e_parser
{ {
$text = strip_tags($text); $text = strip_tags($text);
} }
if (MAGIC_QUOTES_GPC == TRUE) // precaution for badly saved data.
{
$text = stripslashes($text);
}
// Make sure we have a valid count for word wrapping // Make sure we have a valid count for word wrapping

View File

@@ -686,9 +686,9 @@ class e_file
// Use e107.org login. // Use e107.org login.
private function setAuthKey($username,$password) public function setAuthKey($username,$password)
{ {
$now = gmdate('y-m-d H:i'); $now = gmdate('y-m-d H');
$this->authKey = sha1($username.md5($password).$now); $this->authKey = sha1($username.md5($password).$now);
return $this; return $this;
@@ -724,7 +724,7 @@ class e_file
// echo "<script>alert('".$remotefile."')</script>"; // echo "<script>alert('".$remotefile."')</script>";
$result = $this->getRemoteFile($remotefile,$localfile); $result = $this->getRemoteFile($remotefile,$localfile);
if(!file_exists(e_TEMP.$localfile)) if(!file_exists(e_TEMP.$localfile))
{ {
$status = ADMIN_FALSE_ICON."<br /><a href='".$remotefile."'>Download Manually</a>"; $status = ADMIN_FALSE_ICON."<br /><a href='".$remotefile."'>Download Manually</a>";
@@ -741,13 +741,15 @@ class e_file
else else
{ {
$contents = file_get_contents(e_TEMP.$localfile); $contents = file_get_contents(e_TEMP.$localfile);
if($contents == 'false') if(strlen($contents) < 400)
{ {
echo "<div class='e-alert'>Authentication Error</div>"; echo "<script>alert('".$tp->toJS($contents)."')</script>";
exit; return;
} }
} }
// chmod(e_PLUGIN,0777); // chmod(e_PLUGIN,0777);
chmod(e_TEMP.$localfile,0755); chmod(e_TEMP.$localfile,0755);
@@ -759,6 +761,8 @@ class e_file
$destpath = ($type == 'theme') ? e_THEME : e_PLUGIN; $destpath = ($type == 'theme') ? e_THEME : e_PLUGIN;
$typeDiz = ucfirst($type); $typeDiz = ucfirst($type);
@copy(e_TEMP.$localfile,e_BACKUP.$dir.".zip"); // Make a Backup in the system folder. @copy(e_TEMP.$localfile,e_BACKUP.$dir.".zip"); // Make a Backup in the system folder.
if($dir && is_dir($destpath.$dir)) if($dir && is_dir($destpath.$dir))
@@ -770,12 +774,19 @@ class e_file
exit; exit;
} }
if($dir == '')
{
echo "<script>alert('Couldn\'t detect the root folder in the zip.')</script>";
@unlink(e_TEMP.$localfile);
exit;
}
if(is_dir(e_TEMP.$dir)) if(is_dir(e_TEMP.$dir))
{ {
$status = "Unzipping..."; $status = "Unzipping...";
if(!rename(e_TEMP.$dir,$destpath.$dir)) if(!rename(e_TEMP.$dir,$destpath.$dir))
{ {
$alert = $tp->toJS("Couldn't Move ".$typeDiz." to ".$typeDiz." Folder"); $alert = $tp->toJS("Couldn't Move ".e_TEMP.$dir." to ".$destpath.$dir." Folder");
echo "<script>alert('".$alert."')</script>"; echo "<script>alert('".$alert."')</script>";
@unlink(e_TEMP.$localfile); @unlink(e_TEMP.$localfile);
exit; exit;

View File

@@ -1308,10 +1308,10 @@ class e_form
{ {
$text = '<div class="input-append e-search"><i class="icon-search"></i> $text = '<span class="input-append e-search"><i class="icon-search"></i>
'.$this->text($name, $searchVal,20,'class=search-query').' '.$this->text($name, $searchVal,20,'class=search-query').'
<button class="btn btn-primary" name="'.$submitName.'" type="submit">'.LAN_GO.'</button> <button class="btn btn-primary" name="'.$submitName.'" type="submit">'.LAN_GO.'</button>
</div>'; </span>';

View File

@@ -1371,7 +1371,10 @@ class e_navigation
$sc = e107::getScBatch('navigation'); $sc = e107::getScBatch('navigation');
$sc->template = $template; $sc->template = $template;
$ret = $template['start']; $head = $template['start'];
$foot = $template['end'];
$ret = "";
foreach ($data as $_data) foreach ($data as $_data)
{ {
$sc->setVars($_data); $sc->setVars($_data);
@@ -1379,10 +1382,8 @@ class e_navigation
$itemTmpl = count($_data['link_sub']) > 0 ? $template['item_submenu'.$active] : $template['item'.$active]; $itemTmpl = count($_data['link_sub']) > 0 ? $template['item_submenu'.$active] : $template['item'.$active];
$ret .= e107::getParser()->parseTemplate($itemTmpl, TRUE); $ret .= e107::getParser()->parseTemplate($itemTmpl, TRUE);
} }
$ret .= $template['end']; return ($ret != '') ? $head.$ret.$foot : '';
return $ret;
} }
@@ -1499,7 +1500,21 @@ class navigation_shortcodes extends e_shortcode
function sc_link_name($parm='') function sc_link_name($parm='')
{ {
return e107::getParser()->toHtml($this->var['link_name'],false,'defs'); if(!varset($this->var['link_name']))
{
return;
}
if(substr($this->var['link_name'],0,8) == 'submenu.') // BC Fix.
{
list($tmp,$tmp2,$link) = explode('.',$this->var['link_name'],3);
}
else
{
$link = $this->var['link_name'];
}
return e107::getParser()->toHtml($link, false,'defs');
} }
function sc_link_parent($parm='') function sc_link_parent($parm='')

View File

@@ -426,80 +426,34 @@ class themeHandler
} }
} }
function showThemes($mode = 'main')
private function search($name, $searchVal, $submitName, $filterName='', $filterArray=false, $filterVal=false)
{ {
global $pref;
$mes = e107::getMessage();
$ns = e107::getRender();
$tp = e107::getParser();
$frm = e107::getForm(); $frm = e107::getForm();
$srch = preg_replace('/[^\w]/','', vartrue($_GET['srch']));
echo "<div>"; $text = '<span class="input-append e-search"><i class="icon-search"></i>
'.$frm->text($name, $searchVal,20,'class=search-query').'
<button class="btn btn-primary" name="'.$submitName.'" type="submit">'.LAN_GO.'</button>
</span>';
if($mode == "main" || !$mode) // Show Main Configuration // $text .= $this->admin_button($submitName,LAN_SEARCH,'search');
{
foreach ($this->themeArray as $key=>$theme)
{
if($key == $pref['sitetheme'])
{
$text = $this->renderTheme(1, $theme);
}
}
echo "<form enctype='multipart/form-data' method='post' action='".e_SELF."?".$mode."'>\n";
$ns->tablerender(TPVLAN_26.SEP.TPVLAN_33, $mes->render().$text);
}
// Show Admin Configuration return $text;
if($mode == "admin")
{
foreach ($this->themeArray as $key=>$theme)
{
if($key == $pref['admintheme'])
{
$text = $this->renderTheme(2, $theme);
}
}
echo "<form enctype='multipart/form-data' method='post' action='".e_SELF."?".$mode."'>\n";
$ns->tablerender(TPVLAN_26.SEP.TPVLAN_34, $mes->render().$text);
}
// Show Upload Form }
if($mode == "upload")
{
$this->renderUploadForm();
}
// Show All Themes
if($mode == "choose")
{
$text = "";
foreach ($this->themeArray as $key=>$theme)
{
$text .= $this->renderTheme(FALSE, $theme);
// print_a($theme);
}
$text .= "<div class='clear'>&nbsp;</div>";
echo "<form enctype='multipart/form-data' method='post' action='".e_SELF."?".$mode."'>\n";
$ns->tablerender(TPVLAN_26.SEP.TPVLAN_39, $mes->render().$text);
}
if($mode == "online")
{
$e107 = e107::getInstance();
$xml = e107::getXml();
$mes = e107::getMessage();
// $mes->addWarning("This area is experimental.");
$from = intval(varset($_GET['frm']));
$limit = 18; function renderOnline($ajax=false)
// $file = SITEURLBASE.e_PLUGIN_ABS."release/release.php"; // temporary testing {
$xml = e107::getXml();
$mes = e107::getMessage();
$frm = e107::getForm();
$ns = e107::getRender();
$from = intval(varset($_GET['frm']));
$limit = 96;
$srch = preg_replace('/[^\w]/','', vartrue($_GET['srch']));
$file = "http://e107.org/feed?type=theme&frm=".$from."&srch=".$srch."&limit=".$limit; $file = "http://e107.org/feed?type=theme&frm=".$from."&srch=".$srch."&limit=".$limit;
@@ -510,14 +464,9 @@ class themeHandler
$xdata = $xml->loadXMLfile($file,true,false); $xdata = $xml->loadXMLfile($file,true,false);
$total = $xdata['@attributes']['total']; $total = $xdata['@attributes']['total'];
$text = "
<form class='form-search' action='".e_SELF."?".e_QUERY."' id='core-plugin-list-form' method='get'>
<div class='clearfix'>
<div class='span2'>".$frm->search('srch', $srch, 'go', $filterName, $filterArray, $filterVal).$frm->hidden('mode','online')."</div>";
$amount =$limit; $amount =$limit;
/*
if($total > $amount) if($total > $amount)
{ {
//$parms = $total.",".$amount.",".$from.",".e_SELF.'?mode='.$_GET['mode'].'&amp;frm=[FROM]'; //$parms = $total.",".$amount.",".$from.",".e_SELF.'?mode='.$_GET['mode'].'&amp;frm=[FROM]';
@@ -527,19 +476,30 @@ class themeHandler
$text .= "<div class='span5' style='margin-left: 100px;margin-top:10px'>".$tp->parseTemplate("{NEXTPREV=$parms}",TRUE)."</div>"; $text .= "<div class='span5' style='margin-left: 100px;margin-top:10px'>".$tp->parseTemplate("{NEXTPREV=$parms}",TRUE)."</div>";
} }
*/
$text .= "</div></div></form>";
// print_a($xdata); // print_a($xdata);
//TODO use admin_ui including filter capabilities by sending search queries back to the xml script.
// XML data array.
$c = 1; $c = 1;
$text = "<form class='form-search' action='".e_SELF."?".e_QUERY."' id='core-plugin-list-form' method='get'>";
$text .= '<div id="myCarousel" class="carousel slide" data-interval="false">';
$text .= "<div class='form-inline clearfix row-fluid'>";
$text .= $this->search('srch', $srch, 'go', $filterName, $filterArray, $filterVal).$frm->hidden('mode','online');
$text .= '<div class="btn-group" style="margin-left:10px"><a class="btn btn-primary" href="#myCarousel" data-slide="prev">&lsaquo;</a><a class="btn btn-primary" href="#myCarousel" data-slide="next">&rsaquo;</a></div>';
$text .= "{CAROUSEL_INDICATORS}";
$text .= "</div>";
$text .= '<div id="shop" style="margin-top:10px;min-height:585px" class=" carousel-inner">';
if(is_array($xdata['theme'] )) if(is_array($xdata['theme'] ))
{ {
$text .= '<div class="active item">';
$slides = array();
foreach($xdata['theme'] as $r) foreach($xdata['theme'] as $r)
{ {
if(E107_DBG_PATH) if(E107_DBG_PATH)
@@ -559,9 +519,25 @@ class themeHandler
'website' => $r['@attributes']['authorUrl'], 'website' => $r['@attributes']['authorUrl'],
'compatibility' => $r['@attributes']['compatibility'], 'compatibility' => $r['@attributes']['compatibility'],
'description' => varset($r['description']), 'description' => varset($r['description']),
'price' => $r['@attributes']['price'],
'livedemo' => $r['@attributes']['livedemo'],
); );
$text .= $this->renderTheme(FALSE, $theme); $text .= $this->renderTheme(FALSE, $theme);
$c++;
if($c == 19)
{
$text .= '</div><div class="item">';
$slides[] = 1;
$c = 1;
}
/* /*
[author] => e107 Inc [author] => e107 Inc
@@ -601,30 +577,119 @@ class themeHandler
*/ */
} }
$text .= "<div class='clear'>&nbsp;</div>"; $text .= "<div class='clear'>&nbsp;</div>";
$text .= "</div>";
$text .= "</div>";
} }
else else
{ {
$mes->addInfo("No Themes found which match your search criteria"); $mes->addInfo("No Themes found which match your search criteria");
} }
$indicators = '<ol class="carousel-indicators span6">
<li data-target="#myCarousel" data-slide-to="0" class="active"></li>';
foreach($slides as $key=>$v)
$ns->tablerender(TPVLAN_26.SEP."Available for Download", $text. $mes->render()); {
$id = $key + 1;
$indicators .= '<li data-target="#myCarousel" data-slide-to="'.$id.'"></li>';
}
$indicators .= '</ol>';
$text = str_replace("{CAROUSEL_INDICATORS}",$indicators,$text);
$text .= "</form>";
$ns->tablerender(TPVLAN_26.SEP."Available for Download", $text. $mes->render());
}
function showThemes($mode = 'main')
{
global $pref;
$mes = e107::getMessage();
$ns = e107::getRender();
$tp = e107::getParser();
$frm = e107::getForm();
echo "<div>";
if($mode == "main" || !$mode) // Show Main Configuration
{
foreach ($this->themeArray as $key=>$theme)
{
if($key == $pref['sitetheme'])
{
$text = $this->renderTheme(1, $theme);
}
}
echo "<form enctype='multipart/form-data' method='post' action='".e_SELF."?".$mode."'>\n";
$ns->tablerender(TPVLAN_26.SEP.TPVLAN_33, $mes->render().$text);
echo "</form>";
} }
// Show Admin Configuration
echo "</form>\n</div>\n"; if($mode == "admin")
{
foreach ($this->themeArray as $key=>$theme)
{
if($key == $pref['admintheme'])
{
$text = $this->renderTheme(2, $theme);
}
}
echo "<form enctype='multipart/form-data' method='post' action='".e_SELF."?".$mode."'>\n";
$ns->tablerender(TPVLAN_26.SEP.TPVLAN_34, $mes->render().$text);
echo "</form>";
}
// Show Upload Form
if($mode == "upload")
{
$this->renderUploadForm();
}
// Show All Themes
if($mode == "choose")
{
$text = "";
foreach ($this->themeArray as $key=>$theme)
{
$text .= $this->renderTheme(FALSE, $theme);
// print_a($theme);
}
$text .= "<div class='clear'>&nbsp;</div>";
echo "<form enctype='multipart/form-data' method='post' action='".e_SELF."?".$mode."'>\n";
$ns->tablerender(TPVLAN_26.SEP.TPVLAN_39, $mes->render().$text);
$text .= "</form>";
}
if($mode == "online")
{
$this->renderOnline();
}
echo "</div>\n";
} }
@@ -690,6 +755,7 @@ class themeHandler
$preview = "<a href='".e_BASE."news.php?themepreview.".$theme['id']."' title='".TPVLAN_9."' >".($theme['preview'] ? "<img src='".$theme['preview']."' style='border: 1px solid #000;width:200px' alt='' />" : "<img src='".e_IMAGE_ABS."admin_images/nopreview.png' title='".TPVLAN_12."' alt='' />")."</a>"; $preview = "<a href='".e_BASE."news.php?themepreview.".$theme['id']."' title='".TPVLAN_9."' >".($theme['preview'] ? "<img src='".$theme['preview']."' style='border: 1px solid #000;width:200px' alt='' />" : "<img src='".e_IMAGE_ABS."admin_images/nopreview.png' title='".TPVLAN_12."' alt='' />")."</a>";
$description = vartrue($theme['description'],''); $description = vartrue($theme['description'],'');
$compat = (intval($theme['compatibility']) == 2) ? "<span class='label label-warning'>".number_format($theme['compatibility'], 1, '.','')."</span><span class='text-warning'> Recommended!</span>": vartrue(number_format($theme['compatibility'], 1, '.',''),'1.0'); $compat = (intval($theme['compatibility']) == 2) ? "<span class='label label-warning'>".number_format($theme['compatibility'], 1, '.','')."</span><span class='text-warning'> Recommended!</span>": vartrue(number_format($theme['compatibility'], 1, '.',''),'1.0');
$price = ($theme['price'] > 0) ? "<span class='label label-info'><i class='icon-shopping-cart icon-white'></i> ".$theme['price']."</span>" : "<span class='label label-success'>".Free."</span>";
$text = "<table class='table table-striped'>"; $text = "<table class='table table-striped'>";
@@ -699,7 +765,7 @@ class themeHandler
$text .= $website ? "<tr><td style='vertical-align:top; width:24%'><b>".TPVLAN_5."</b>:</td><td style='vertical-align:top'>".$website."</td></tr>" : ""; $text .= $website ? "<tr><td style='vertical-align:top; width:24%'><b>".TPVLAN_5."</b>:</td><td style='vertical-align:top'>".$website."</td></tr>" : "";
$text .= $theme['date'] ? "<tr><td style='vertical-align:top; width:24%'><b>".TPVLAN_6."</b>:</td><td style='vertical-align:top'>".$theme['date']."</td></tr>" : ""; $text .= $theme['date'] ? "<tr><td style='vertical-align:top; width:24%'><b>".TPVLAN_6."</b>:</td><td style='vertical-align:top'>".$theme['date']."</td></tr>" : "";
$text .= $compat ? "<tr><td style='vertical-align:top; width:24%'><b>".TPVLAN_57."</b>:</td><td style='vertical-align:top'>".$compat."</td></tr>" : ""; $text .= $compat ? "<tr><td style='vertical-align:top; width:24%'><b>".TPVLAN_57."</b>:</td><td style='vertical-align:top'>".$compat."</td></tr>" : "";
$text .= "<tr><td style='vertical-align:top; width:24%'><b>Price</b>:</td><td style='vertical-align:top'>".$price."</td></tr>";
$text .= $description ? "<tr><td style='vertical-align:top; width:24%'><b>Description</b>:</td><td style='vertical-align:top'>".$description."</td></tr>" : ""; $text .= $description ? "<tr><td style='vertical-align:top; width:24%'><b>Description</b>:</td><td style='vertical-align:top'>".$description."</td></tr>" : "";
@@ -894,42 +960,13 @@ class themeHandler
$author = ($theme['email'] ? "<a href='mailto:".$theme['email']."' title='".$theme['email']."'>".$theme['author']."</a>" : $theme['author']); $author = ($theme['email'] ? "<a href='mailto:".$theme['email']."' title='".$theme['email']."'>".$theme['author']."</a>" : $theme['author']);
$website = ($theme['website'] ? "<a href='".$theme['website']."' rel='external'>".$theme['website']."</a>" : ""); $website = ($theme['website'] ? "<a href='".$theme['website']."' rel='external'>".$theme['website']."</a>" : "");
$preview = "<a href='".e_BASE."news.php?themepreview.".$theme['id']."' title='".TPVLAN_9."' >".($theme['preview'] ? "<img src='".$theme['preview']."' style='border: 1px solid #000;width:200px' alt='' />" : "<img src='".e_IMAGE_ABS."admin_images/nopreview.png' title='".TPVLAN_12."' alt='' />")."</a>"; // $preview = "<a href='".e_BASE."news.php?themepreview.".$theme['id']."' title='".TPVLAN_9."' >".($theme['preview'] ? "<img src='".$theme['preview']."' style='border: 1px solid #000;width:200px' alt='' />" : "<img src='".e_IMAGE_ABS."admin_images/nopreview.png' title='".TPVLAN_12."' alt='' />")."</a>";
$main_icon = ($pref['sitetheme'] != $theme['path']) ? "<input class='top' type='image' src='".e_IMAGE_ABS."admin_images/main_32.png' name='selectmain[".$theme['id']."]' alt=\"".TPVLAN_10."\" title=\"".TPVLAN_10."\" />" : E_32_TRUE; $main_icon = ($pref['sitetheme'] != $theme['path']) ? "<input class='top' type='image' src='".e_IMAGE_ABS."admin_images/main_32.png' name='selectmain[".$theme['id']."]' alt=\"".TPVLAN_10."\" title=\"".TPVLAN_10."\" />" : E_32_TRUE;
// $info_icon = "<a data-toggle='modal' data-target='".e_SELF."' href='#themeInfo_".$theme['id']."' class='e-tip' title='".TPVLAN_7."'><img src='".e_IMAGE_ABS."admin_images/info_32.png' alt='' class='icon S32' /></a>"; // $info_icon = "<a data-toggle='modal' data-target='".e_SELF."' href='#themeInfo_".$theme['id']."' class='e-tip' title='".TPVLAN_7."'><img src='".e_IMAGE_ABS."admin_images/info_32.png' alt='' class='icon S32' /></a>";
$info_icon = "<a data-toggle='modal' data-modal-caption=\"".$theme['name']." ".$theme['version']."\" href='".e_SELF."?id=".$theme['path']."' data-target='#uiModal' title='".TPVLAN_7."'>".E_32_CAT_ABOUT."</a>"; $info_icon = "<a data-toggle='modal' data-modal-caption=\"".$theme['name']." ".$theme['version']."\" href='".e_SELF."?id=".$theme['path']."' data-target='#uiModal' title='".TPVLAN_7."'>".E_32_CAT_ABOUT."</a>";
$preview_icon = "<a title='Preview : ".$theme['name']."' rel='external' class='e-dialog' href='".e_BASE."index.php?themepreview.".$theme['id']."'>".E_32_SEARCH."</a>"; // $preview_icon = "<a title='Preview : ".$theme['name']."' rel='external' class='e-dialog' href='".e_BASE."index.php?themepreview.".$theme['id']."'>".E_32_SEARCH."</a>";
$admin_icon = ($pref['admintheme'] != $theme['path'] ) ? "<input class='top' type='image' src='".e_IMAGE_ABS."e107_icon_32.png' name='selectadmin[".$theme['id']."]' alt=\"".TPVLAN_32."\" title=\"".TPVLAN_32."\" />\n" : E_32_TRUE; $admin_icon = ($pref['admintheme'] != $theme['path'] ) ? "<input class='top' type='image' src='".e_IMAGE_ABS."e107_icon_32.png' name='selectadmin[".$theme['id']."]' alt=\"".TPVLAN_32."\" title=\"".TPVLAN_32."\" />\n" : E_32_TRUE;
$price = '';
if($_GET['mode'] == 'online')
{
$d = http_build_query($theme,false,'&');
$url = e_SELF."?src=".base64_encode($d);
$id = $frm->name2id($theme['name']);
$main_icon = "<a data-src='".$url."' href='#' data-target='{$id}' data-loading='".e_IMAGE."/generic/loading_32.gif' class='e-ajax' title='Download' ><img class='top' src='".e_IMAGE_ABS."icons/download_32.png' alt='' /></a> ";
$info_icon = "<a data-toggle='modal' data-modal-caption=\"".$theme['name']." ".$theme['version']."\" href='".$url."&amp;info=1' data-cache='false' data-target='#uiModal' title='".TPVLAN_7."'>".trim(E_32_CAT_ABOUT)."</a>";
//XXX modal-Cache is currently enabled by default. Awaiting inclusion of data-cache feature.
// See here: https://github.com/twitter/bootstrap/pull/4224
}
if(!in_array($theme['path'], $this->approvedAdminThemes))
{
$admin_icon = "";
}
if($theme['name'] == 'bootstrap')
{
// print_a($theme);
}
//
// $thumbPath = (substr($theme['thumbnail'],0,4) == 'http') ? $theme['thumbnail'] : e_THEME.$theme['path'] ."/".$theme['preview'][0];
// $thumbnail = "<a href='".e_BASE."news.php?themepreview.".$theme['id']."' title='".TPVLAN_9."' >";
if(substr($theme['thumbnail'],0,4) == 'http') if(substr($theme['thumbnail'],0,4) == 'http')
{ {
@@ -948,11 +985,54 @@ class themeHandler
} }
$thumbnail = "<img src='".$thumbPath."' style='width:200px; height:130px;' alt='' />"; $thumbnail = "<img src='".$thumbPath."' style='width:200px; height:130px;' alt='' />";
$preview_icon = "<a title='Preview : ".$theme['name']."' rel='external' class='e-modal' href='".$previewPath."'>".E_32_SEARCH."</a>";
if($_GET['mode'] == 'online')
{
$d = http_build_query($theme,false,'&');
$url = e_SELF."?src=".base64_encode($d);
$id = $frm->name2id($theme['name']);
$LAN_DOWNLOAD = ($theme['price'] > 0) ? "Buy/Download" : "Download";
$main_icon = "<a data-src='".$url."' href='#' data-target='{$id}' data-loading='".e_IMAGE."/generic/loading_32.gif' class='e-ajax' title='".$LAN_DOWNLOAD."' ><img class='top' src='".e_IMAGE_ABS."icons/download_32.png' alt='' /></a> ";
$info_icon = "<a data-toggle='modal' data-modal-caption=\"".$theme['name']." ".$theme['version']."\" href='".$url."&amp;info=1' data-cache='false' data-target='#uiModal' title='".TPVLAN_7."'>".trim(E_32_CAT_ABOUT)."</a>";
if($theme['livedemo'])
{
$previewPath = $theme['livedemo'];
}
//XXX modal-Cache is currently enabled by default. Awaiting inclusion of data-cache feature.
// See here: https://github.com/twitter/bootstrap/pull/4224
$price = ($theme['price'] > 0) ? "<span class='label label-info pull-right'><i class='icon-shopping-cart icon-white'></i> ".$theme['price']."</span>" : "<span class='label label-success pull-right'>".Free."</span>";
}
$preview_icon = "<a title='Preview/Live-Demo : ".$theme['name']."' data-modal-caption=\"".$theme['name']." ".$theme['version']."\" rel='external' class='e-modal' href='".$previewPath."'>".E_32_SEARCH."</a>";
if(!in_array($theme['path'], $this->approvedAdminThemes))
{
$admin_icon = "";
}
if($theme['name'] == 'bootstrap')
{
// print_a($theme);
}
//
// $thumbPath = (substr($theme['thumbnail'],0,4) == 'http') ? $theme['thumbnail'] : e_THEME.$theme['path'] ."/".$theme['preview'][0];
// $thumbnail = "<a href='".e_BASE."news.php?themepreview.".$theme['id']."' title='".TPVLAN_9."' >";
// $thumbnail .= "</a>"; // $thumbnail .= "</a>";
// Choose a Theme to Install. // Choose a Theme to Install.
if(!$mode) if(!$mode)
{ {
// styles NEED to be put into style.css // styles NEED to be put into style.css
@@ -972,11 +1052,14 @@ class themeHandler
$borderStyle = 'well'; $borderStyle = 'well';
$text = " $text = "
<div class='f-left block-text admin-theme-cell ".$borderStyle."'> <div class='f-left block-text admin-theme-cell ".$borderStyle."'>
<div class='well admin-theme-thumb'>".$thumbnail."</div> <div class='well admin-theme-thumb'>".$thumbnail."</div>
<div id='".$frm->name2id($theme['name'])."' class='admin-theme-options'>".$main_icon.$admin_icon.$info_icon.$preview_icon."</div> <div id='".$frm->name2id($theme['name'])."' class='admin-theme-options'>".$main_icon.$admin_icon.$info_icon.$preview_icon."</div>
<div class='admin-theme-title'>".$theme['name']." ".$theme['version']."</div> <div class='admin-theme-title'><small style='white-space:nowrap;display:inline-block;width:160px;overflow:hidden'>".$theme['name']." ".$theme['version']."</small>
".$price."
</div>
</div>"; </div>";
return $text; return $text;
} }
@@ -1018,6 +1101,7 @@ class themeHandler
$text .= "<tr><td style='vertical-align:top; width:25%'><b>".TPVLAN_7."</b>:</td><td style='vertical-align:top'>".strip_tags($theme['info'],'b')."</td></tr>"; $text .= "<tr><td style='vertical-align:top; width:25%'><b>".TPVLAN_7."</b>:</td><td style='vertical-align:top'>".strip_tags($theme['info'],'b')."</td></tr>";
$text .= "<tr><td style='vertical-align:top; width:25%'><b>".LAN_CATEGORY."</b>:</td><td style='vertical-align:top'>".$theme['category']."</td></tr>"; $text .= "<tr><td style='vertical-align:top; width:25%'><b>".LAN_CATEGORY."</b>:</td><td style='vertical-align:top'>".$theme['category']."</td></tr>";
// $text .= "<tr><td style='vertical-align:top; width:25%'><b>Price</b>:</td><td style='vertical-align:top'>".$price."</td></tr>";
$text .= "<tr><td style='vertical-align:top; width:25%'><b>".TPVLAN_49."</b>:</td> $text .= "<tr><td style='vertical-align:top; width:25%'><b>".TPVLAN_49."</b>:</td>
<td style='vertical-align:top' colspan='2'>"; <td style='vertical-align:top' colspan='2'>";
$text .= ($theme['xhtmlcompliant']) ? "W3C XHTML ".$theme['xhtmlcompliant'] : "Not Specified"; $text .= ($theme['xhtmlcompliant']) ? "W3C XHTML ".$theme['xhtmlcompliant'] : "Not Specified";

View File

@@ -24,7 +24,7 @@ define("WMLAN_02","Message");
define("WMLAN_04","Message Text"); define("WMLAN_04","Message Text");
define("WMLAN_05","Enclose"); define("WMLAN_05","Enclose");
define("WMLAN_06","If ticked, the message will be rendered inside box"); define("WMLAN_06","When enabled, the message will be rendered inside a box");
define("WMLAN_07","Override standard system to use {WMESSAGE} shortcode:"); define("WMLAN_07","Override standard system to use {WMESSAGE} shortcode:");
// define("WMLAN_08","Preferences"); // define("WMLAN_08","Preferences");

View File

@@ -303,11 +303,13 @@ if(!$text = $e107cache->retrieve("nq_chatbox"))
{ {
$tp->parseTemplate("{SETIMAGE: w=40}",true); // set thumbnail size. $tp->parseTemplate("{SETIMAGE: w=40}",true); // set thumbnail size.
// FIXME - move to template // FIXME - move to template
$CHATBOX_TEMPLATE['start'] = "<ul class='unstyled'>"; $CHATBOX_TEMPLATE['start'] = "<ul class='media-list unstyled'>";
$CHATBOX_TEMPLATE['item'] = "<li> $CHATBOX_TEMPLATE['item'] = "<li class='media'>
{CB_AVATAR} <b>{USERNAME}</b>&nbsp; <span class='media-object pull-left'>{CB_AVATAR}</span>
<div class='media-body'><b>{USERNAME}</b>&nbsp;
<small class='muted smalltext'>{TIMEDATE}</small><br /> <small class='muted smalltext'>{TIMEDATE}</small><br />
<p style='margin-left:50px'>{MESSAGE}</p> <p>{MESSAGE}</p>
</div>
</li>\n"; </li>\n";
$CHATBOX_TEMPLATE['end'] = "</ul>"; $CHATBOX_TEMPLATE['end'] = "</ul>";

View File

@@ -170,7 +170,7 @@ SC_END
SC_BEGIN LM_ADMIN_CONFIGURE SC_BEGIN LM_ADMIN_CONFIGURE
if(ADMIN == TRUE) { if(ADMIN == TRUE) {
return $parm == 'href' ? e_PLUGIN.'login_menu/config.php' : '<a class="login_menu_link config" id="login_menu_link_config" href="'.e_PLUGIN.'login_menu/config.php">'.LOGIN_MENU_L48.'</a>'; return $parm == 'href' ? e_PLUGIN_ABS.'login_menu/config.php' : '<a class="login_menu_link config" id="login_menu_link_config" href="'.e_PLUGIN_ABS.'login_menu/config.php">'.LOGIN_MENU_L48.'</a>';
} }
return ''; return '';
SC_END SC_END

View File

@@ -1,8 +1,9 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<!-- $Id: theme.xml,v 1.9 2009-08-31 14:37:24 e107coders Exp $ --> <e107Theme name="blank" version="1.0" date="2031-05-01" compatibility="2.0" livedemo='http://e107.org'>
<e107Theme name="blank" version="0.1" date="2008-12-01" compatibility="2.0"> <author name ="e107 Inc" email="nospam@e107.org" url="http://e107.org" />
<author name ="Desislav Yosifov [SonicE]" email="support@free-source.net" url="http://free-source.net" /> <summary>Bootstrap e107 admin theme</summary>
<description>Blank e107 admin theme</description> <description>Blank e107 Theme</description>
<category>generic</category>
<compliance xhtml="1.1" css="2.1" /> <compliance xhtml="1.1" css="2.1" />
<plugins> <plugins>
<plugin name='chatbox_menu' url='core' /> <plugin name='chatbox_menu' url='core' />
@@ -10,6 +11,11 @@
<screenshots> <screenshots>
<image></image> <image></image>
</screenshots> </screenshots>
<keywords>
<word>blank</word>
<word>empty</word>
<word>template</word>
</keywords>
<layouts> <layouts>
<layout name='default' title='Default' default='true' /> <layout name='default' title='Default' default='true' />
<layout name='home' title='Home'> <layout name='home' title='Home'>

View File

@@ -203,9 +203,9 @@ img.S32:hover {}
.adminlist .col-selection-cont { position: relative; float:right; } .adminlist .col-selection-cont { position: relative; float:right; }
div.e-search input[type='text'] { padding-left:25px } span.e-search input[type='text'] { padding-left:25px }
div.e-search i { margin-right:-20px; margin-left:5px; margin-top:0px; z-index:100; position:relative; } span.e-search i { margin-right:-20px; margin-left:5px; margin-top:-7px; z-index:100; position:relative; }
div.e-search { margin-bottom:-5px; margin-top:10px } // span.e-search { margin-bottom:-5px; margin-top:10px }
/******** SyS Messages / Message text formatting */ /******** SyS Messages / Message text formatting */
.s-message .s-message-title { height: 32px; background: 0 50% no-repeat; padding-left: 42px; line-height: 32px; } .s-message .s-message-title { height: 32px; background: 0 50% no-repeat; padding-left: 42px; line-height: 32px; }

View File

@@ -20,13 +20,6 @@ footer { padding:60px }
.nextprev-bar { clear: both; padding: 5px; font-size: 14px; margin: 5px; border:1px solid #ddd; } /* Page NextPrev navigation block */ .nextprev-bar { clear: both; padding: 5px; font-size: 14px; margin: 5px; border:1px solid #ddd; } /* Page NextPrev navigation block */
/******** SyS Messages / Message text formatting */
/* message boxes */
/* message text (overall) */
/******** SyS Messages / Message text formatting */
.s-message .s-message-title { height: 32px; background: 0 50% no-repeat; padding-left: 42px; line-height: 32px; } .s-message .s-message-title { height: 32px; background: 0 50% no-repeat; padding-left: 42px; line-height: 32px; }
@@ -49,33 +42,6 @@ i.s-message-debug { background-position: -1480px 0; width: 32px; height: 32px;
.required { color:red } .required { color:red }
/* THEME SPECIFIC CSS *********************************************************************************************/ /* THEME SPECIFIC CSS *********************************************************************************************/
/******** Page Base */
.wrapper { width: 100%; }
.header { padding: 20px 15px 0; }
.header-content { border: 1px solid #DDDDDD}
.page-body { padding: 20px 15px 0; }
.footer {}
legend { font-size: 14px; font-weight: bold; padding: 5px; }
/******** Block Elements */
.block { border: 1px solid #DDDDDD; margin-bottom: 10px;}
.block-text { padding: 10px 10px 10px; }
.block h1.caption { padding: 5px 10px 5px; vertical-align: middle; }
.block h2.caption, .block h4.caption { padding: 5px 10px 5px; border-bottom: 1px solid #DDDDDD; }
/******** Horizontal navigation ADMIN_NAV_ALT */
.navigation { border: 1px solid #DDDDDD;}
/******** Layout */
.main-table { width: 100%; border: 0 none; }
.col-left { width: 220px; }
.col-right { width: 220px;}
.col-main { padding: 0 15px 0 15px;}
.inner-wrapper { margin: 0 5px }
/******** Horizontal navigation ADMIN_NAV_ALT */
.navigation { border: 1px solid #DDDDDD;}
/******** News item styling */ /******** News item styling */
@@ -88,6 +54,7 @@ legend { font-size: 14px; font-weight: bold; padding: 5px; }
div.view-item { margin-bottom:50px } div.view-item { margin-bottom:50px }
/******** FEATUREBOX PLUGIN */ /******** FEATUREBOX PLUGIN */
/*
#featurebox-ajax-container { display: block } #featurebox-ajax-container { display: block }
#featurebox-ajax-container img { padding: 1px; margin: 5px; border: 1px solid #DDDDDD } #featurebox-ajax-container img { padding: 1px; margin: 5px; border: 1px solid #DDDDDD }
@@ -101,7 +68,7 @@ div.featurebox-nav a.featurebox-nav-next:hover,
div.featurebox-nav a.featurebox-nav-prev, div.featurebox-nav a.featurebox-nav-prev,
div.featurebox-nav a.featurebox-nav-prev:hover { text-decoration: none; font-size: 16px } div.featurebox-nav a.featurebox-nav-prev:hover { text-decoration: none; font-size: 16px }
*/
.form-signin { .form-signin {
max-width: 300px; max-width: 300px;

View File

@@ -118,10 +118,11 @@ function tablestyle($caption, $text, $mode='')
} }
} }
$SC_WRAPPER['NAVIGATION|s'] = '<div class="well sidebar-nav">{---}</div><!--/.well -->';
// TODO Convert to : default-home and default-other layouts. // TODO Convert to : default-home and default-other layouts.
$HEADER['default'] = ' $HEADER['default'] = '
<div class="navbar navbar-inverse navbar-fixed-top"> <div class="navbar navbar-inverse navbar-fixed-top">
<div class="navbar-inner"> <div class="navbar-inner">
@@ -144,10 +145,7 @@ $HEADER['default'] = '
<div class="container-fluid"> <div class="container-fluid">
<div class="row-fluid"> <div class="row-fluid">
<div class="span3"> <div class="span3">
<div class="well sidebar-nav"> {NAVIGATION|s=side}
{NAVIGATION=side}
</div><!--/.well -->
{SETSTYLE=menu} {SETSTYLE=menu}
{MENU=1} {MENU=1}
</div><!--/span--> </div><!--/span-->

View File

@@ -348,19 +348,21 @@ $(document).ready(function()
$(this).closest("li").removeClass("active"); $(this).closest("li").removeClass("active");
$(this).switchClass( "link-active", "link", 0 ); $(this).switchClass( "link-active", "link", 0 );
}); });
var id = $(this).attr("href"), hash = id.substr(1), form = $('.admin-menu')[0]; // FIXME - a better way to detect the page form var id = $(this).attr("href"), hash = id.split('#')[1], form = $('.admin-menu')[0]; // FIXME - a better way to detect the page form
$(this).switchClass( "link", "link-active", 30 ); $(this).switchClass( "link", "link-active", 30 );
$(this).closest("li").addClass("active"); $(this).closest("li").addClass("active");
$(id).removeClass('e-hideme').show({ $(id).removeClass('e-hideme').show({
effect: "slide" effect: "slide"
}); });
// 'remember' the active navigation pane // 'remember' the active navigation pane
window.location.hash = 'nav-' + hash; if(hash) {
if(form) { window.location.hash = 'nav-' + hash;
$(form).attr('action', $(form).attr('action').split('#')[0] + '#nav-' + hash); if(form) {
} $(form).attr('action', $(form).attr('action').split('#')[0] + '#nav-' + hash);
}
return false; //FIXME See admin/prefs navigation. return false;
}
}); });
// plugin navigation hash // plugin navigation hash