From 4572cd7ceb2b9e100619cb648f8259d784eed314 Mon Sep 17 00:00:00 2001 From: Cameron Date: Wed, 4 Feb 2015 20:36:56 -0800 Subject: [PATCH] Issue #682 and other 'wrong avatar' issues in chatbox, online-menu etc. New $tp->toAvatar() method introduced. --- .../shortcodes/batch/comment_shortcodes.php | 8 +-- e107_handlers/e_parse_class.php | 63 ++++++++++++++++++- e107_plugins/chatbox_menu/chatbox_menu.php | 2 +- e107_plugins/online/online_menu.php | 6 +- e107_plugins/online/online_menu_template.php | 4 +- e107_plugins/online/online_shortcodes.php | 9 ++- 6 files changed, 82 insertions(+), 10 deletions(-) diff --git a/e107_core/shortcodes/batch/comment_shortcodes.php b/e107_core/shortcodes/batch/comment_shortcodes.php index 6c27dcde4..1c6cc2137 100644 --- a/e107_core/shortcodes/batch/comment_shortcodes.php +++ b/e107_core/shortcodes/batch/comment_shortcodes.php @@ -107,12 +107,12 @@ class comment_shortcodes extends e_shortcode $tp = e107::getParser(); // return $this->var['user_image']; - // $url = $tp->thumbUrl($this->var['user_image']); - // $text = $tp->parseTemplate("{USER_AVATAR=".vartrue($this->var['user_image'],USERIMAGE)."}"); - $text = $tp->parseTemplate("{USER_AVATAR=".$this->var['user_id']."}"); - $text = + // $text = $tp->parseTemplate("{USER_AVATAR=".$this->var['user_id']."}"); + + $text = $tp->toAvatar($this->var); + $text .= "