From eff4faea7f3c95440f02ea45d0be4f67236e2bf3 Mon Sep 17 00:00:00 2001 From: brettp Date: Wed, 3 Nov 2010 22:13:10 +0000 Subject: Fixes #1320: Bundled mods use elgg_echo()'s internal string substitution. git-svn-id: http://code.elgg.org/elgg/trunk@7229 36083f99-b078-4883-b0ff-0f9b5a30f544 --- .../views/default/object/groupforumtopic.php | 56 +++++++++++----------- 1 file changed, 28 insertions(+), 28 deletions(-) (limited to 'mod/groups/views/default/object/groupforumtopic.php') diff --git a/mod/groups/views/default/object/groupforumtopic.php b/mod/groups/views/default/object/groupforumtopic.php index fb67797d3..4250e9aff 100644 --- a/mod/groups/views/default/object/groupforumtopic.php +++ b/mod/groups/views/default/object/groupforumtopic.php @@ -27,53 +27,53 @@ $u = get_user($last_user); if (elgg_get_context() == "search") { var_export($counter); if($counter == 1){ - $info = "

" . sprintf(elgg_echo('groups:forum:created:single'), $forum_created, $counter) . "
"; + $info = "

" . elgg_echo('groups:forum:created:single', array($forum_created, $counter)) . "
"; }else{ - $info = "

" . sprintf(elgg_echo('groups:forum:created'), $forum_created, $counter) . "
"; + $info = "

" . elgg_echo('groups:forum:created', array($forum_created, $counter)) . "
"; } - if (($last_time) && ($u)) $info.= sprintf(elgg_echo('groups:lastupdated'), elgg_view_friendly_time($last_time), " getURL() . "\">" . $u->name . ""); - $info .= '

'; + if (($last_time) && ($u)) $info.= elgg_echo('groups:lastupdated', array(elgg_view_friendly_time($last_time), " getURL() . "\">" . $u->name . "")); + $info .= '

'; //get the group avatar $icon = elgg_view("profile/icon",array('entity' => $u, 'size' => 'tiny')); - //get the group and topic title - $info .= "

" . elgg_echo('groups:topic') . ": guid}&group_guid={$group->guid}\">{$title}

"; - if ($group instanceof ElggGroup) { - $info .= "

" . elgg_echo('group') . ": getURL()}\">".htmlentities($group->name, ENT_QUOTES, 'UTF-8') ."

"; - } + //get the group and topic title + $info .= "

" . elgg_echo('groups:topic') . ": guid}&group_guid={$group->guid}\">{$title}

"; + if ($group instanceof ElggGroup) { + $info .= "

" . elgg_echo('group') . ": getURL()}\">".htmlentities($group->name, ENT_QUOTES, 'UTF-8') ."

"; + } } else { if($counter == 1){ - $info = "

" . sprintf(elgg_echo('groups:forum:created:single'), $forum_created, $counter) . "

"; + $info = "

" . elgg_echo('groups:forum:created:single', array($forum_created, $counter)) . "

"; }else{ - $info = "

" . sprintf(elgg_echo('groups:forum:created'), $forum_created, $counter) . "

"; + $info = "

" . elgg_echo('groups:forum:created', array($forum_created, $counter)) . "

"; } - $info .= "

" . elgg_echo('groups:started') . " " . $topic_owner->name . ": guid}&group_guid={$group->guid}\">{$title}

"; + $info .= "

" . elgg_echo('groups:started') . " " . $topic_owner->name . ": guid}&group_guid={$group->guid}\">{$title}

"; - if (groups_can_edit_discussion($vars['entity'], elgg_get_page_owner()->owner_guid)) { - // display the delete link to those allowed to delete - $info .= "
"; + if (groups_can_edit_discussion($vars['entity'], elgg_get_page_owner()->owner_guid)) { + // display the delete link to those allowed to delete + $info .= ""; - } +} if (($last_time) && ($u)) { $commenter_link = "getURL()}\">$u->name"; - $text = sprintf(elgg_echo('groups:lastcomment'), elgg_view_friendly_time($last_time), $commenter_link); + $text = elgg_echo('groups:lastcomment', array(elgg_view_friendly_time($last_time), $commenter_link)); $info .= "

$text

"; } - //get the user avatar + //get the user avatar $icon = elgg_view("profile/icon",array('entity' => $topic_owner, 'size' => 'tiny')); } -- cgit v1.2.3