From 6fd1aef610a8541891d90c19a4de7b5358f14f58 Mon Sep 17 00:00:00 2001 From: Tijn Kuyper Date: Wed, 3 Apr 2019 12:53:59 +0200 Subject: [PATCH] Forum - Allow styling of button in { SEARCH} #3584 --- e107_plugins/forum/shortcodes/batch/forum_shortcodes.php | 7 +++++-- .../forum/shortcodes/batch/viewforum_shortcodes.php | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/e107_plugins/forum/shortcodes/batch/forum_shortcodes.php b/e107_plugins/forum/shortcodes/batch/forum_shortcodes.php index b6003fdf2..f94bc427d 100644 --- a/e107_plugins/forum/shortcodes/batch/forum_shortcodes.php +++ b/e107_plugins/forum/shortcodes/batch/forum_shortcodes.php @@ -164,7 +164,7 @@ class forum_shortcodes extends e_shortcode return $text; } - function sc_search() + function sc_search($parm='') { if(!deftrue('FONTAWESOME') || !$srchIcon = e107::getParser()->toGlyph('fa-search')) @@ -172,6 +172,9 @@ class forum_shortcodes extends e_shortcode $srchIcon = LAN_SEARCH; } + $buttonclass = (!empty($parm['buttonclass'])) ? "class='".$parm['buttonclass']."'" : "class='btn btn-default btn-secondary button'"; + + // String candidate for USERLIST wrapper return "
@@ -181,7 +184,7 @@ class forum_shortcodes extends e_shortcode - + diff --git a/e107_plugins/forum/shortcodes/batch/viewforum_shortcodes.php b/e107_plugins/forum/shortcodes/batch/viewforum_shortcodes.php index 84b99b2e0..eeb3297b5 100644 --- a/e107_plugins/forum/shortcodes/batch/viewforum_shortcodes.php +++ b/e107_plugins/forum/shortcodes/batch/viewforum_shortcodes.php @@ -302,7 +302,7 @@ } - function sc_search() + function sc_search($parm='') { if(!deftrue('FONTAWESOME') || !$srchIcon = e107::getParser()->toGlyph('fa-search')) @@ -310,6 +310,9 @@ $srchIcon = LAN_SEARCH; } + $buttonclass = (!empty($parm['buttonclass'])) ? "class='".$parm['buttonclass']."'" : "class='btn btn-default btn-secondary button'"; + + // String candidate for USERLIST wrapper return " @@ -319,7 +322,7 @@ - +