@@ -21,7 +21,7 @@ function register() {
2121         $ this  ->name         = plugin_lang_get ( 'title '  );
2222         $ this  ->description  = plugin_lang_get ( 'description '  );
2323         $ this  ->page         = 'config ' ;
24-          $ this  ->version      = '1.3.5  ' ;
24+          $ this  ->version      = '1.3.6  ' ;
2525
2626         $ this  ->requires ['MantisCore ' ] = '1.3.0 ' ;
2727         # this plugin can coexist with MantisCoreFormatting. 
@@ -231,8 +231,8 @@ function add_tags() {
231231         $ t_extra_link_tags  = 'target="_blank" ' ;
232232         # BBCode parsers. 
233233         $ this  ->t_bbCode ->addParser ('link ' , '/\[url\](.*?)\[\/url\]/s ' , '<a  '  . $ t_extra_link_tags  . ' href="$1">$1</a> ' , '$1 ' );
234-          $ this  ->t_bbCode ->addParser ('namedlink ' , '/\[url\=(.*?)\ ](.*?)\[\/url\]/s ' , '<a  '  . $ t_extra_link_tags  . ' href="$1">$2 </a> ' , '$2  ' );
235-          $ this  ->t_bbCode ->addParser ('mention ' , '/\[url\=(.*? )\ mention](.*?)\[\/url\]/s ' , '<span class="mention"><a  '  . $ t_extra_link_tags  . ' href="$1">$2</a></span> ' , '$2 ' );
234+          $ this  ->t_bbCode ->addParser ('namedlink ' , '/\[url\=(.*?)(\smention)?\ ](.*?)\[\/url\]/s ' , '<a  '  . $ t_extra_link_tags  . ' href="$1">$3 </a> ' , '$3  ' );
235+          $ this  ->t_bbCode ->addParser ('mention ' , '/\[url\=([^\s]* )\ mention\ ](.*?)\[\/url\]/s ' , '<span class="mention"><a  '  . $ t_extra_link_tags  . ' href="$1">$2</a></span> ' , '$2 ' );
236236         $ this  ->t_bbCode ->addParser ('email ' , '/\[email\]([a-z0-9\-_\.\+]+@[a-z0-9\-]+\.[a-z0-9\-\.]+?)\[\/email\]/s ' , '<a  '  . $ t_extra_link_tags  . ' href="mailto:$1">$1</a> ' , '$1 ' );
237237         $ this  ->t_bbCode ->addParser ('named-email ' , '/\[email=([a-z0-9\-_\.\+]+@[a-z0-9\-]+\.[a-z0-9\-\.]+?)\](.+?)\[\/email\]/s ' , '<a  '  . $ t_extra_link_tags  . ' href="mailto:$1">$2</a> ' , '$2 ' );
238238         $ this  ->t_bbCode ->addParser ('color ' , '/\[color=([\#a-z0-9]+?)\](.*?)\[\/color\]/s ' , '<span class="bbcolor-$1">$2</span> ' , '$2 ' );
0 commit comments