From 4e6c4a41666f742ea79a720c9a07cd4b9f2b2faa Mon Sep 17 00:00:00 2001 From: leo Date: Fri, 9 Dec 2016 18:08:17 +0100 Subject: [PATCH 01/11] issue quotation marks https://github.com/e107inc/e107/issues/2129 --- e107_languages/English/lan_error.php | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/e107_languages/English/lan_error.php b/e107_languages/English/lan_error.php index a777234b7..be471298c 100644 --- a/e107_languages/English/lan_error.php +++ b/e107_languages/English/lan_error.php @@ -50,17 +50,17 @@ define("LAN_ERROR_32", "To complete the upgrade, copy the following text into yo define("LAN_ERROR_33", "Processing error! Normally, I would redirect to the home page."); define("LAN_ERROR_34", "Unknown error! Please inform the site administrator you saw this:"); -define('LAN_ERROR_35', "Error 400 - Bad Request"); -define('LAN_ERROR_36', "There is a formatting error in the web page you are trying to access."); -define('LAN_ERROR_37', "Error Icon"); -define('LAN_ERROR_38', "Sorry, but the site is unavailable due to a temporary fault"); -define('LAN_ERROR_39', "Please try again in a few minutes"); -define('LAN_ERROR_40', "If the problem persists, please contact the site administrator"); -define('LAN_ERROR_41', "The reported error is:"); -define('LAN_ERROR_42', "Additional error information: "); -define('LAN_ERROR_43', "Site unavailable temporarily"); -define('LAN_ERROR_44', "Site logo"); +define("LAN_ERROR_35", "Error 400 - Bad Request"); +define("LAN_ERROR_36", "There is a formatting error in the web page you are trying to access."); +define("LAN_ERROR_37", "Error Icon"); +define("LAN_ERROR_38", "Sorry, but the site is unavailable due to a temporary fault"); +define("LAN_ERROR_39", "Please try again in a few minutes"); +define("LAN_ERROR_40", "If the problem persists, please contact the site administrator"); +define("LAN_ERROR_41", "The reported error is:"); +define("LAN_ERROR_42", "Additional error information: "); +define("LAN_ERROR_43", "Site unavailable temporarily"); +define("LAN_ERROR_44", "Site logo"); -define('LAN_ERROR_45', "What can you do now?"); -define('LAN_ERROR_46', "Check log for details."); -?> \ No newline at end of file +define("LAN_ERROR_45", "What can you do now?"); +define("LAN_ERROR_46", "Check log for details."); +?> From 98f294352650bf3e93c4028f19d5f207f177e012 Mon Sep 17 00:00:00 2001 From: leo Date: Fri, 9 Dec 2016 18:10:32 +0100 Subject: [PATCH 02/11] issue quotation marks https://github.com/e107inc/e107/issues/2129 --- e107_languages/English/lan_fpw.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/e107_languages/English/lan_fpw.php b/e107_languages/English/lan_fpw.php index b9e317cbc..95cb95ac0 100644 --- a/e107_languages/English/lan_fpw.php +++ b/e107_languages/English/lan_fpw.php @@ -41,14 +41,14 @@ define("LAN_FPW14", "has been submitted by someone with the IP of"); define("LAN_FPW15", "This does not mean your password has yet been reset. You must navigate to the link shown below to complete the reset process."); define("LAN_FPW16", "If you did not request to have your password reset and you do NOT want it reset, you may simply ignore this email"); define("LAN_FPW17", "The link below will be valid for 48 hours."); -define('LAN_FPW18', "Password reset requested"); -define('LAN_FPW19', "Email send failed"); -define('LAN_FPW20', "Email send succeeded"); -define('LAN_FPW21', "User clicked on password reset link"); +define("LAN_FPW18", "Password reset requested"); +define("LAN_FPW19", "Email send failed"); +define("LAN_FPW20", "Email send succeeded"); +define("LAN_FPW21", "User clicked on password reset link"); define("LAN_FPW_100", "Forgot your password?"); define("LAN_FPW_101", "Not to worry. Just enter your email address below and we'll send you an instruction email for recovery."); define("LAN_FPW_102", "Reset Password"); -?> \ No newline at end of file +?> From 5e4735f1120c721fdc1a65ed0fdb207649fbea57 Mon Sep 17 00:00:00 2001 From: Cameron Date: Fri, 9 Dec 2016 09:59:32 -0800 Subject: [PATCH 03/11] $frontendData is empty. --- e107_admin/plugin.php | 2 +- e107_handlers/file_class.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/e107_admin/plugin.php b/e107_admin/plugin.php index 9735122d1..f99b869fd 100644 --- a/e107_admin/plugin.php +++ b/e107_admin/plugin.php @@ -3678,7 +3678,7 @@ $text .= " 'main/edit' => 'main/list' ); - protected \$menuTitle = '".vartrue($tp->filter($vars['pluginName']), $pluginTitle)."'; + protected \$menuTitle = '".vartrue($pluginTitle, $tp->filter($vars['pluginName']))."'; } diff --git a/e107_handlers/file_class.php b/e107_handlers/file_class.php index 3f4eba969..c6fbf767d 100644 --- a/e107_handlers/file_class.php +++ b/e107_handlers/file_class.php @@ -413,7 +413,7 @@ class e_file /** * Grab a remote file and save it in the /temp directory. requires CURL * @param $remote_url - * @param $local_file + * @param $local_file string filename to save as * @param $type media, temp, or import * @return boolean TRUE on success, FALSE on failure (which includes absence of CURL functions) */ From 465a1309af4013eb9ffbd352ec68e232ae027593 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 10 Dec 2016 10:47:14 -0800 Subject: [PATCH 04/11] Session clear() with no key will now reset data array. Fix for nav-bar avatar alignment --- e107_handlers/session_handler.php | 12 ++++++++++-- e107_themes/bootstrap3/style.css | 2 +- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/e107_handlers/session_handler.php b/e107_handlers/session_handler.php index 86f4e6f6e..9d73a51e1 100644 --- a/e107_handlers/session_handler.php +++ b/e107_handlers/session_handler.php @@ -333,8 +333,13 @@ class e_session * @param string $key * @return e_session */ - public function clear($key) + public function clear($key=null) { + if($key == null) // clear all under this namespace. + { + $this->_data = array(); // must be set to array() not unset. + } + unset($this->_data[$key]); return $this; } @@ -451,7 +456,10 @@ class e_session break; default: - session_module_name('files'); + if(!isset($_SESSION)) + { + session_module_name('files'); + } break; } diff --git a/e107_themes/bootstrap3/style.css b/e107_themes/bootstrap3/style.css index 2dfe3a42a..f41b35ae9 100644 --- a/e107_themes/bootstrap3/style.css +++ b/e107_themes/bootstrap3/style.css @@ -143,7 +143,7 @@ table label.checkbox { #sidebar .panel-body ul.list-unstyled { padding-left:0} - +li.dropdown-avatar > a.dropdown-toggle { padding:0; padding-top:9px; padding-bottom:10px} From 59cacab22855157063172a549e0c82aa7fda17c4 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 10 Dec 2016 11:36:22 -0800 Subject: [PATCH 05/11] Fix for login page message styling/placement. --- e107_core/templates/login_template.php | 5 ++++- login.php | 6 +++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/e107_core/templates/login_template.php b/e107_core/templates/login_template.php index bf59fd9c7..5f30448da 100644 --- a/e107_core/templates/login_template.php +++ b/e107_core/templates/login_template.php @@ -89,7 +89,7 @@ $LOGIN_TEMPLATE['page']['header'] = " "; $LOGIN_TEMPLATE['page']['body'] = ' - + {LOGIN_TABLE_LOGINMESSAGE} '; if (e107::pref('core', 'password_CHAP') == 2) { @@ -110,6 +110,9 @@ $LOGIN_WRAPPER['page']['LOGIN_TABLE_SECIMG_TEXTBOC'] = "
$LOGIN_WRAPPER['page']['LOGIN_TABLE_REMEMBERME'] = "
{---}
"; $LOGIN_WRAPPER['page']['LOGIN_TABLE_SUBMIT'] = "
{---}
"; $LOGIN_WRAPPER['page']['LOGIN_TABLE_FOOTER_USERREG'] = "
{---}
"; +$LOGIN_WRAPPER['page']['LOGIN_TABLE_LOGINMESSAGE'] = "
{---}
"; + + // $LOGIN_WRAPPER['page']['LOGIN_TABLE_FPW_LINK'] = "
{---}
"; $LOGIN_TEMPLATE['page']['body'] .= ' diff --git a/login.php b/login.php index 12fed7e6c..898a599a9 100644 --- a/login.php +++ b/login.php @@ -101,7 +101,11 @@ if (!USER || getperms('0')) $login_message = SITENAME; // $login_message = LAN_LOGIN_3." | ".SITENAME; - echo LOGINMESSAGE; + if(strpos($LOGIN_TABLE_HEADER,'LOGIN_TABLE_LOGINMESSAGE') === false && strpos($LOGIN_TABLE,'LOGIN_TABLE_LOGINMESSAGE') === false) + { + echo LOGINMESSAGE; + } + echo $tp->parseTemplate($LOGIN_TABLE_HEADER,true, $sc); $ns->tablerender($login_message, $text, 'login_page'); echo $tp->parseTemplate($LOGIN_TABLE_FOOTER, true, $sc); From e974bdd665bf4bc968e00ade22cf6b3f1b1050d2 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 10 Dec 2016 16:10:56 -0800 Subject: [PATCH 06/11] Captcha login message fix. Backward compat styling fixes. --- e107_handlers/login.php | 11 +++++------ e107_plugins/forum/forum.css | 2 ++ e107_web/css/backcompat.css | 3 ++- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/e107_handlers/login.php b/e107_handlers/login.php index 8af5e5354..f7e39ca15 100644 --- a/e107_handlers/login.php +++ b/e107_handlers/login.php @@ -165,12 +165,11 @@ class userlogin // Check secure image if (!$forceLogin && $pref['logcode'] && extension_loaded('gd')) { - require_once(e_HANDLER."secure_img_handler.php"); - $sec_img = new secure_image; - if (!$sec_img->verify_code($_POST['rand_num'], $_POST['code_verify'])) - { // Invalid code - return $this->invalidLogin($username,LOGIN_BAD_CODE); + if ($secImgResult = e107::getSecureImg()->invalidCode($_POST['rand_num'], $_POST['code_verify'])) // Invalid code + { + return $this->invalidLogin($username, LOGIN_BAD_CODE, $secImgResult); } + } if (empty($this->userData)) // May have retrieved user data earlier @@ -578,7 +577,7 @@ class userlogin $doCheck = true; break; case LOGIN_BAD_CODE : - $message = LAN_LOGIN_23; + $message = $extra_text; // LAN_LOGIN_23; $this->logNote('LAN_ROLL_LOG_02', $username); break; case LOGIN_NOT_ACTIVATED : diff --git a/e107_plugins/forum/forum.css b/e107_plugins/forum/forum.css index 71ce9e4cd..b611eb04a 100644 --- a/e107_plugins/forum/forum.css +++ b/e107_plugins/forum/forum.css @@ -13,9 +13,11 @@ .forum-attachment-file { margin-top:15px; } .forum-user-combo { padding-bottom:5px } +/* ul.newforumposts-menu { padding-left: 10px; } ul.newforumposts-menu li { margin-bottom: 15px; } +*/ div.forum-poll-results { padding-left:0 } .forum-viewtopic-customtitle { diff --git a/e107_web/css/backcompat.css b/e107_web/css/backcompat.css index aa17e68da..b68a96bfc 100644 --- a/e107_web/css/backcompat.css +++ b/e107_web/css/backcompat.css @@ -27,4 +27,5 @@ div.news-empty { text-align:center; font-weight: bold } div.checkboxes label.checkbox { display: block } -textarea.bbarea { margin:0; } \ No newline at end of file +textarea.bbarea { margin:0; } +#chatbox-input-block { text-align:center } \ No newline at end of file From 268004bd71cf2fd089196fab3be1818d37cf01a6 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 10 Dec 2016 16:38:39 -0800 Subject: [PATCH 07/11] BC Fixes --- e107_handlers/form_handler.php | 2 +- e107_handlers/shortcode_handler.php | 3 ++- e107_plugins/forum/forum.php | 15 +++++++++++---- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/e107_handlers/form_handler.php b/e107_handlers/form_handler.php index 1b641438e..b9a7fa985 100644 --- a/e107_handlers/form_handler.php +++ b/e107_handlers/form_handler.php @@ -1730,7 +1730,7 @@ e107::getDebug()->log($sc_parameters); $options['pattern'] = vartrue($options['pattern'],'[\S]{4,}'); $options['required'] = varset($options['required'], 1); - $options['class'] = vartrue($options['class'],'e-password'); + $options['class'] = vartrue($options['class'],'e-password tbox'); e107::js('core', 'password/jquery.pwdMeter.js', 'jquery', 2); diff --git a/e107_handlers/shortcode_handler.php b/e107_handlers/shortcode_handler.php index c059585ce..1a80b054d 100644 --- a/e107_handlers/shortcode_handler.php +++ b/e107_handlers/shortcode_handler.php @@ -100,6 +100,7 @@ class e_parse_shortcode protected $sc_style = array(); // Former $sc_style global variable. Internally used - performance reasons protected $editableCodes = array(); // Array of editable shortcode data. protected $editableActive = false; + protected $nowrap = false; function __construct() { @@ -460,7 +461,7 @@ class e_parse_shortcode // echo "

Couldn't Find Class '".$className."' in ".$path."

"; } - e107::getDebug()->log( "
Couldn't Load: ".$path." with class-name: {$className} and pluginName {$pluginName}
"); + // e107::getDebug()->log( "
Couldn't Load: ".$path." with class-name: {$className} and pluginName {$pluginName}
"); // TODO - throw exception? diff --git a/e107_plugins/forum/forum.php b/e107_plugins/forum/forum.php index a04c0212a..d60545b56 100644 --- a/e107_plugins/forum/forum.php +++ b/e107_plugins/forum/forum.php @@ -306,21 +306,28 @@ str_replace("[x]", ($total_topics+$total_replies), LAN_FORUM_0031)." ($total_top -$FORUM_TEMPLATE = e107::getTemplate('forum','forum'); // required to use v2.x wrapper shortcode wrappers. -if(empty($FORUM_TEMPLATE)) //v1.x fallback. + + +if(empty($FORUM_TEMPLATE)) { - include(e_PLUGIN.'forum/templates/forum_template.php'); + // include(e_PLUGIN.'forum/templates/forum_template.php'); // Override with theme template - if (file_exists(THEME.'forum_template.php')) + if (file_exists(THEME.'forum_template.php')) //v1.x fallback. { + include(e_PLUGIN.'forum/templates/forum_template.php'); include_once(THEME.'forum_template.php'); } elseif(file_exists(THEME.'templates/forum/forum_template.php')) { + $FORUM_TEMPLATE = e107::getTemplate('forum','forum'); require_once(THEME.'templates/forum/forum_template.php'); } + else //v2.x + { + $FORUM_TEMPLATE = e107::getTemplate('forum','forum'); // required to use v2.x wrapper shortcode wrappers. + } } if(is_array($FORUM_TEMPLATE) && deftrue('BOOTSTRAP',false)) // new v2.x format. From b105b854e6d76b4b4f0cf15e4dea89d5a85f500f Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 10 Dec 2016 17:05:12 -0800 Subject: [PATCH 08/11] Bc Fixes. Fix for broken navigation when using {SITELINKS} shortcode. --- e107_handlers/sitelinks_class.php | 14 +++++++++++--- e107_web/css/backcompat.css | 4 +++- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/e107_handlers/sitelinks_class.php b/e107_handlers/sitelinks_class.php index 51cb5e201..a13922d71 100644 --- a/e107_handlers/sitelinks_class.php +++ b/e107_handlers/sitelinks_class.php @@ -260,6 +260,8 @@ class sitelinks } + + // If submenu: Fix Name, Add Indentation. if ($submenu == TRUE) { @@ -274,10 +276,14 @@ class sitelinks // Convert any {e_XXX} to absolute URLs (relative ones sometimes get broken by adding e_HTTP at the front) $linkInfo['link_url'] = $tp -> replaceConstants($linkInfo['link_url'], TRUE, TRUE); // replace {e_xxxx} - if(strpos($linkInfo['link_url'],"{") !== FALSE) + if(strpos($linkInfo['link_url'],"{") !== false) { $linkInfo['link_url'] = $tp->parseTemplate($linkInfo['link_url'], TRUE); // shortcode in URL support - dynamic urls for multilanguage. } + elseif($linkInfo['link_url'][0] != '/') + { + $linkInfo['link_url'] = e_HTTP.ltrim($linkInfo['link_url'],'/'); + } // By default links are not highlighted. if (isset($linkInfo['link_expand']) && $linkInfo['link_expand']) @@ -306,7 +312,7 @@ class sitelinks elseif ($linkInfo['link_url']) { // Only add the e_BASE if it actually has an URL. - $linkInfo['link_url'] = (strpos($linkInfo['link_url'], '://') === FALSE && strpos($linkInfo['link_url'], 'mailto:') !== 0 ? e_HTTP.$linkInfo['link_url'] : $linkInfo['link_url']); + $linkInfo['link_url'] = (strpos($linkInfo['link_url'], '://') === FALSE && strpos($linkInfo['link_url'], 'mailto:') !== 0 ? $linkInfo['link_url'] : $linkInfo['link_url']); // Only check if its highlighted if it has an URL if ($this->hilite($linkInfo['link_url'], $style['linkstart_hilite'])== TRUE) @@ -333,7 +339,7 @@ class sitelinks // Open link in a new window. (equivalent of target='_blank' ) $link_append = ($linkInfo['link_open'] == 1) ? " rel='external'" : ""; } - +e107::getDebug()->log($linkInfo['link_url']); // Remove default images if its a button and add new image at the start. if ($linkInfo['link_button']) { @@ -371,6 +377,8 @@ class sitelinks $_link = $linkstart.$indent.$_link; + e107::getDebug()->log($linkInfo['link_url']); + global $SITELINKSTYLE; if(!$SITELINKSTYLE) { diff --git a/e107_web/css/backcompat.css b/e107_web/css/backcompat.css index b68a96bfc..f6033242f 100644 --- a/e107_web/css/backcompat.css +++ b/e107_web/css/backcompat.css @@ -28,4 +28,6 @@ div.news-empty { text-align:center; font-weight: bold } div.checkboxes label.checkbox { display: block } textarea.bbarea { margin:0; } -#chatbox-input-block { text-align:center } \ No newline at end of file +#chatbox-input-block { text-align:center } +ul.breadcrumb li { display:inline-block; padding-right:5px;} +ul.breadcrumb li span.divider { padding-left:5px; } \ No newline at end of file From afd979b75690f7687539758884832f3e75b78623 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=B3na=20Lore?= Date: Sun, 11 Dec 2016 20:30:27 +0100 Subject: [PATCH 09/11] Issue #2127 - Fix for proper usage of provider names. --- e107_handlers/user_handler.php | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/e107_handlers/user_handler.php b/e107_handlers/user_handler.php index e0fa68d85..c21ac88f0 100644 --- a/e107_handlers/user_handler.php +++ b/e107_handlers/user_handler.php @@ -1123,7 +1123,35 @@ class e_user_provider public function setProvider($provider) { - $provider = ucfirst(strtolower($provider)); + $provider = strtolower($provider); + + switch($provider) + { + case 'aol': + $provider = 'AOL'; + break; + + case 'googleopenid': + $provider = 'GoogleOpenID'; + break; + + case 'linkedin': + $provider = 'LinkedIn'; + break; + + case 'myspace': + $provider = 'MySpace'; + break; + + case 'openid': + $provider = 'OpenID'; + break; + + default: + $provider = ucfirst($provider); + break; + } + if(isset($this->_config['providers'][$provider]) && $this->_config['providers'][$provider]['enabled']) { if($this->_config['providers'][$provider]['enabled'] && vartrue($this->_config['providers'][$provider]['keys'])) From 366d3fe5cf9a4f6869051c5a15327d1c835a3070 Mon Sep 17 00:00:00 2001 From: Cameron Date: Mon, 12 Dec 2016 08:11:41 -0800 Subject: [PATCH 10/11] Styling fixes. Debug timer totals fix. --- e107_handlers/db_debug_class.php | 27 +++++++++++++++++++++++---- e107_plugins/log/stats.php | 11 ++++++++--- e107_themes/bootstrap3/style.css | 2 +- 3 files changed, 32 insertions(+), 8 deletions(-) diff --git a/e107_handlers/db_debug_class.php b/e107_handlers/db_debug_class.php index dd0f1bd8b..002b6642f 100644 --- a/e107_handlers/db_debug_class.php +++ b/e107_handlers/db_debug_class.php @@ -412,11 +412,30 @@ class e107_db_debug { $aSum['%Time']=$totTime ? number_format(100.0 * ($aSum['Time'] / $totTime), 0) : 0; $aSum['%DB Time']=$db_time ? number_format(100.0 * ($aSum['DB Time'] / $db_time), 0) : 0; $aSum['%DB Count']=($sql->db_QueryCount()) ? number_format(100.0 * ($aSum['DB Count'] / ($sql->db_QueryCount())), 0) : 0; - $aSum['Time']=number_format($aSum['Time']*1000.0, 1); + $aSum['Time']=number_format($aSum['Time'] * 1000.0, 1); $aSum['DB Time']=number_format($aSum['DB Time']*1000.0, 1); - $text .= "".implode(" ", $aSum)."  \n"; - $text .= "\n
\n"; + + $text .= " +   + Total + ".$aSum['%Time']." + ".$aSum['%DB Time']." + ".$aSum['%DB Count']." + ".$aSum['Time']." + ".$aSum['DB Time']." + ".$aSum['DB Count']." + ".$tMarker['Memory']." + ".$tMarker['OB Lev']." + + + "; + + + // $text .= "".implode(" ", $aSum)."  \n"; + + $text .= "\n
\n"; + // // Stats by Table @@ -461,7 +480,7 @@ class e107_db_debug { $aSum['%DB Time']=$db_time ? number_format(100.0 * ($aSum['DB Time'] / $db_time), 0) : 0; $aSum['%DB Count']=($sql->db_QueryCount()) ? number_format(100.0 * ($aSum['DB Count'] / ($sql->db_QueryCount())), 0) : 0; $aSum['DB Time']=number_format($aSum['DB Time']*1000.0, 1); - $text .= "".implode(" ", array_values($aSum))." \n"; + $text .= "".implode(" ", array_values($aSum))." \n"; $text .= "\n
\n"; return $text; diff --git a/e107_plugins/log/stats.php b/e107_plugins/log/stats.php index b9069a0c3..c46fea0a3 100644 --- a/e107_plugins/log/stats.php +++ b/e107_plugins/log/stats.php @@ -816,12 +816,16 @@ class siteStats $url = str_replace($this->plugFolder,'',$url); + + if($truncate) { - return e107::getParser()->text_truncate($url,50); + $result = e107::getParser()->text_truncate($url,50); + + return $result; } - return $url; + return trim($url); } @@ -842,6 +846,7 @@ class siteStats $totalArray = array(); $totalv = 0; $totalu = 0; + $total = 0; foreach ($this -> fileInfo as $k => $v) { $found = (strpos($k,'error/') === 0); @@ -871,7 +876,7 @@ class siteStats if($info['ttl']) { $percentage = round(($info['ttl']/$totalv) * 100, 2); - $text .= "\n ".$this->getLabel($key)." + $text .= "\n ".$this->getLabel($key)." \n".$this -> bar($percentage, $info['ttl']." [".$info['unq']."]")."\n".$percentage."%\n\n"; } } diff --git a/e107_themes/bootstrap3/style.css b/e107_themes/bootstrap3/style.css index f41b35ae9..1ab931824 100644 --- a/e107_themes/bootstrap3/style.css +++ b/e107_themes/bootstrap3/style.css @@ -143,7 +143,7 @@ table label.checkbox { #sidebar .panel-body ul.list-unstyled { padding-left:0} -li.dropdown-avatar > a.dropdown-toggle { padding:0; padding-top:9px; padding-bottom:10px} +li.dropdown-avatar > a.dropdown-toggle { padding:9px 15px 10px 0; } From 8e917817d672021c0479d9f1ab85fa499abf69dc Mon Sep 17 00:00:00 2001 From: Cameron Date: Mon, 12 Dec 2016 09:02:14 -0800 Subject: [PATCH 11/11] News: New frontend event added: user_news_item_viewed --- news.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/news.php b/news.php index e52d85fbd..9f507ae82 100644 --- a/news.php +++ b/news.php @@ -510,6 +510,8 @@ if ($action == 'extend') $news = $sql->fetch(); $id = $news['news_category']; // Use category of this news item to generate next/prev links + e107::getEvent()->trigger('user_news_item_viewed', $news); + //***NEW [SecretR] - comments handled inside now e107::setRegistry('news/page_allow_comments', !$news['news_allow_comments']); if(!$news['news_allow_comments'] && isset($_POST['commentsubmit'])) @@ -1006,12 +1008,13 @@ else if ($action == "item") { unset($news['news_render_type']); + e107::getEvent()->trigger('user_news_item_viewed', $news); + //e107::getDebug()->log($news); } // $template = false; $ix->render_newsitem($news, 'default', '', $template, $param); - - - + + $i++; }