diff options
author | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-11-03 22:13:10 +0000 |
---|---|---|
committer | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2010-11-03 22:13:10 +0000 |
commit | eff4faea7f3c95440f02ea45d0be4f67236e2bf3 (patch) | |
tree | 57d51ef4bc84547d60c9a6faae7d5ff5d82d00f9 /mod/search | |
parent | 4b501dda1d62195531e4c2ab1bd84971c0cd4e37 (diff) | |
download | elgg-eff4faea7f3c95440f02ea45d0be4f67236e2bf3.tar.gz elgg-eff4faea7f3c95440f02ea45d0be4f67236e2bf3.tar.bz2 |
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
Diffstat (limited to 'mod/search')
-rw-r--r-- | mod/search/index.php | 4 | ||||
-rw-r--r-- | mod/search/views/default/search/comments/entity.php | 4 | ||||
-rw-r--r-- | mod/search/views/default/search/listing.php | 2 | ||||
-rw-r--r-- | mod/search/views/default/search/startblurb.php | 2 | ||||
-rw-r--r-- | mod/search/views/rss/search/comments/entity.php | 4 |
5 files changed, 8 insertions, 8 deletions
diff --git a/mod/search/index.php b/mod/search/index.php index c68fb4a0f..b042d596f 100644 --- a/mod/search/index.php +++ b/mod/search/index.php @@ -244,7 +244,7 @@ if ($search_type != 'entities' || $search_type == 'all') { $searched_words = search_remove_ignored_words($query, 'array'); $highlighted_query = search_highlight_words($searched_words, $query); -$body = elgg_view_title(sprintf(elgg_echo('search:results'), "\"$highlighted_query\"")); +$body = elgg_view_title(elgg_echo('search:results', array("\"$highlighted_query\""))); if (!$results_html) { $body .= elgg_view('page_elements/contentwrapper', array('body' => elgg_echo('search:no_results'))); @@ -258,6 +258,6 @@ if (!$results_html) { $layout_view = search_get_search_view($params, 'layout'); $layout = elgg_view($layout_view, array('params' => $params, 'body' => $body)); -$title = sprintf(elgg_echo('search:results'), "\"{$params['query']}\""); +$title = elgg_echo('search:results', array("\"{$params['query']}\"")); echo elgg_view_page($title, $layout); diff --git a/mod/search/views/default/search/comments/entity.php b/mod/search/views/default/search/comments/entity.php index 008455242..0cd760664 100644 --- a/mod/search/views/default/search/comments/entity.php +++ b/mod/search/views/default/search/comments/entity.php @@ -17,7 +17,7 @@ if ($owner instanceof ElggUser) { // @todo Sometimes we find comments on entities we can't display... if ($entity->getVolatileData('search_unavailable_entity')) { - $title = sprintf(elgg_echo('search:comment_on'), elgg_echo('search:unavailable_entity')); + $title = elgg_echo('search:comment_on', array(elgg_echo('search:unavailable_entity'))); // keep anchor for formatting. $title = "<a>$title</a>"; } else { @@ -35,7 +35,7 @@ if ($entity->getVolatileData('search_unavailable_entity')) { $title = elgg_echo('item:' . $entity->getType()); } - $title = sprintf(elgg_echo('search:comment_on'), $title); + $title = elgg_echo('search:comment_on', array($title)); $url = $entity->getURL() . '#comment_' . $entity->getVolatileData('search_match_annotation_id'); $title = "<a href=\"$url\">$title</a>"; } diff --git a/mod/search/views/default/search/listing.php b/mod/search/views/default/search/listing.php index c9dda25f0..d84d567d4 100644 --- a/mod/search/views/default/search/listing.php +++ b/mod/search/views/default/search/listing.php @@ -84,7 +84,7 @@ $more = ($more_check > 0) ? $more_check : 0; if ($more) { $title_key = ($more == 1) ? 'comment' : 'comments'; - $more_str = sprintf(elgg_echo('search:more'), $count, $type_str); + $more_str = elgg_echo('search:more', array($count, $type_str)); $more_link = "<div class='search_listing'><a href=\"$url\">$more_str</a></div>"; } else { $more_link = ''; diff --git a/mod/search/views/default/search/startblurb.php b/mod/search/views/default/search/startblurb.php index 2b7230709..3ffa39e68 100644 --- a/mod/search/views/default/search/startblurb.php +++ b/mod/search/views/default/search/startblurb.php @@ -4,4 +4,4 @@ * @subpackage Core */ -echo sprintf(elgg_echo("tag:search:startblurb"), $vars['query']); +echo elgg_echo("tag:search:startblurb", array($vars['query'])); diff --git a/mod/search/views/rss/search/comments/entity.php b/mod/search/views/rss/search/comments/entity.php index 9bdc062c7..46ef87a14 100644 --- a/mod/search/views/rss/search/comments/entity.php +++ b/mod/search/views/rss/search/comments/entity.php @@ -16,7 +16,7 @@ if ($author) { // @todo Sometimes we find comments on entities we can't display... if ($entity->getVolatileData('search_unavailable_entity')) { - $title = sprintf(elgg_echo('search:comment_on'), elgg_echo('search:unavailable_entity')); + $title = elgg_echo('search:comment_on', array(elgg_echo('search:unavailable_entity'))); } else { if ($entity->getType() == 'object') { $title = $entity->title; @@ -32,7 +32,7 @@ if ($entity->getVolatileData('search_unavailable_entity')) { $title = elgg_echo('item:' . $entity->getType()); } - $title = sprintf(elgg_echo('search:comment_on'), $title); + $title = elgg_echo('search:comment_on', array($title)); $title .= ' ' . elgg_echo('search:comment_by') . ' ' . $author_name; $url = $entity->getURL() . '#annotation-' . $entity->getVolatileData('search_match_annotation_id'); } |