aboutsummaryrefslogtreecommitdiff
path: root/mod/file/search.php
diff options
context:
space:
mode:
Diffstat (limited to 'mod/file/search.php')
-rw-r--r--mod/file/search.php24
1 files changed, 12 insertions, 12 deletions
diff --git a/mod/file/search.php b/mod/file/search.php
index e92cf0362..b0120d932 100644
--- a/mod/file/search.php
+++ b/mod/file/search.php
@@ -2,7 +2,7 @@
/**
* Elgg file search
- *
+ *
* @package ElggFile
*/
@@ -10,7 +10,7 @@
// Load Elgg engine
require_once(dirname(dirname(dirname(__FILE__))) . "/engine/start.php");
-
+
// Get input
$md_type = 'simpletype';
$tag = get_input('tag');
@@ -31,17 +31,17 @@
}
}
$page_owner = get_input('page_owner',0);
- if ($page_owner) {
+ if ($page_owner) {
set_page_owner($page_owner);
} else {
if ($friends) {
- set_page_owner($friends);
+ set_page_owner($friends);
} else {
if ($owner_guid > 0 && !is_array($owner_guid))
set_page_owner($owner_guid);
}
}
-
+
if (is_callable('group_gatekeeper')) group_gatekeeper();
if (empty($tag)) {
@@ -49,12 +49,12 @@
$area2 = elgg_view_title(elgg_echo('file:type:all'));
$area2 = elgg_view('page_elements/content_header', array('context' => "everyone", 'type' => 'file'));
} else {
- $title = sprintf(elgg_echo('searchtitle'),$tag);
+ $title = elgg_echo('searchtitle',array($tag));
if (is_array($owner_guid)) {
//$area2 = elgg_view_title(elgg_echo("file:friends:type:" . $tag));
$area2 = elgg_view('page_elements/content_header', array('context' => "friends", 'type' => 'file'));
} else if (elgg_get_page_owner_guid() && elgg_get_page_owner_guid() != get_loggedin_userid()) {
- //$area2 = elgg_view_title(sprintf(elgg_echo("file:user:type:" . $tag),elgg_get_page_owner()->name));
+ //$area2 = elgg_view_title(elgg_echo("file:user:type:" . $tag,array(elgg_get_page_owner()->name)));
$area2 = elgg_view('page_elements/content_header', array('context' => "mine", 'type' => 'file'));
} else{
//$area2 = elgg_view_title(elgg_echo("file:type:" . $tag));
@@ -68,7 +68,7 @@
} else {
$area1 = get_filetype_cloud();
}
-
+
elgg_push_context('search');
$offset = (int)get_input('offset', 0);
@@ -87,13 +87,13 @@
} else {
$area2 .= elgg_list_entities(array('types' => 'object', 'subtypes' => 'file', 'owner_guid' => $owner_guid, 'limit' => $limit, 'offset' => $offset));
}
-
+
elgg_pop_context();
-
+
$content = "<div class='files'>".$area1.$area2."</div>";
-
+
$body = elgg_view_layout('one_column_with_sidebar', $content);
-
+
echo elgg_view_page($title, $body);
?> \ No newline at end of file