diff --git a/e107_core/shortcodes/batch/comment_shortcodes.php b/e107_core/shortcodes/batch/comment_shortcodes.php index 560cc7713..73bf10ce9 100644 --- a/e107_core/shortcodes/batch/comment_shortcodes.php +++ b/e107_core/shortcodes/batch/comment_shortcodes.php @@ -99,11 +99,14 @@ class comment_shortcodes extends e_shortcode $pref = e107::getPref(); $REPLY = ''; - if($this->var['comment_lock'] != "1" && $this->var['comment_blocked'] < 1) + if(USERID || $pref['anon_post'] == 1) { - if ($thisaction == "comment" && $pref['nested_comments']) + if($this->var['comment_lock'] != "1" && $this->var['comment_blocked'] < 1) { - $REPLY = "".COMLAN_326.""; + if ($thisaction == "comment" && $pref['nested_comments']) + { + $REPLY = "".COMLAN_326.""; + } } } return $REPLY; @@ -431,10 +434,10 @@ class comment_shortcodes extends e_shortcode if($prov == 'facebook' || $prov == 'twitter') { //TODO Move styling to e107.css - $text = "Share"; + $text = "Share"; $text .= e107::getForm()->checkbox('comment_share',$prov,true); - $text .= "Share"; + $text .= LAN_SHARE; return $text; } } diff --git a/e107_core/templates/nextprev_template.php b/e107_core/templates/nextprev_template.php index 8a43b7ab8..c010ae9c0 100644 --- a/e107_core/templates/nextprev_template.php +++ b/e107_core/templates/nextprev_template.php @@ -42,9 +42,9 @@ $NEXTPREV_TEMPLATE['default_separator'] = ' '; /* ****************** Default when Bootstrap is enabled ************** */ -$NEXTPREV_TEMPLATE['bootstrap_start'] = "\n"; -$NEXTPREV_TEMPLATE['bootstrap_nav_caption'] = ''; +$NEXTPREV_TEMPLATE['bootstrap_start'] = "\n"; +$NEXTPREV_TEMPLATE['bootstrap_nav_caption'] = ''; $NEXTPREV_TEMPLATE['bootstrap_nav_first'] = '
  • '; $NEXTPREV_TEMPLATE['bootstrap_nav_prev'] = '
  • '; diff --git a/e107_handlers/comment_class.php b/e107_handlers/comment_class.php index 3c950b919..c3e330041 100644 --- a/e107_handlers/comment_class.php +++ b/e107_handlers/comment_class.php @@ -1204,14 +1204,12 @@ class comment //$from = $from + $this->commentsPerPage; - // from calculations are done by eNav() js. - return " - Previous - - Next - - "; - + // from calculations are done by eNav() js. + if($this->totalComments > $this->commentsPerPage) + { + return "" . LAN_PREVIOUS . " + " . LAN_NEXT . ""; + } } @@ -1306,7 +1304,7 @@ class comment foreach ($files as $file=>$perms) { unset($e_comment, $key); - include (e_PLUGIN.$file."/e_comment.php"); + include_once (e_PLUGIN.$file."/e_comment.php"); if ($e_comment && is_array($e_comment)) { $key = $e_comment['eplug_comment_ids']; diff --git a/e107_handlers/js_manager.php b/e107_handlers/js_manager.php index c047f1d4b..d6a3e3d17 100644 --- a/e107_handlers/js_manager.php +++ b/e107_handlers/js_manager.php @@ -1030,9 +1030,10 @@ class e_jsmanager $tp = e107::getParser(); $options = $this->arrayMergeDeepArray(array($this->_e_js_settings)); $json = $tp->toJSON($options); - $js = 'jQuery.extend(e107.settings, ' . $json . ');'; - echo ''; - echo "\n"; + echo "\n"; break; case 'framework': // CDN frameworks - rendered before consolidation script (if enabled) diff --git a/e107_plugins/forum/forum_viewtopic.php b/e107_plugins/forum/forum_viewtopic.php index fb08876f1..8ecf1977c 100644 --- a/e107_plugins/forum/forum_viewtopic.php +++ b/e107_plugins/forum/forum_viewtopic.php @@ -734,7 +734,7 @@ class e107ForumThread exit; } - $totalPosts = $this->threadInfo['thread_total_replies']; // + 1; // add 1 for the original post . ie. not a reply. + $totalPosts = $this->threadInfo['thread_total_replies'] + 1; // add +1 for the original post. ie. not a reply. $this->pages = ceil(($totalPosts) / $this->perPage); $this->noInc = false; } diff --git a/e107_plugins/forum/newforumposts_menu.php b/e107_plugins/forum/newforumposts_menu.php index c654862c7..090d4c072 100755 --- a/e107_plugins/forum/newforumposts_menu.php +++ b/e107_plugins/forum/newforumposts_menu.php @@ -39,9 +39,12 @@ LEFT JOIN `#user` AS u ON u.user_id = p.post_user WHERE {$maxage} p.post_forum IN ({$forumList}) ORDER BY p.post_datestamp DESC LIMIT 0, ".$menu_pref['newforumposts_display']; +// Get forum plugin preferences. +$plugForumPrefs = e107::getPlugConfig('forum')->getPref(); +// New MySQL class instantiation to avoid overrides. +$db = new e_db_mysql(); - - +// TODO: cache menu. if($results = $sql->gen($qry)) { $text = " -
    -

    -
    {GOTOPAGES}
    -
    {QUICKREPLY}
    -
    {BUTTONSX}
    +
    +
    +
    +
    +
    +
    + {GOTOPAGES}
    - {THREADSTATUS} - - "; +
    +
    + {BUTTONSX} +
    +
    +
    +
    +
    + {QUICKREPLY} +
    +
    +{THREADSTATUS} +";