aboutsummaryrefslogtreecommitdiff
path: root/mod/search/index.php
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-02-07 02:38:51 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-02-07 02:38:51 +0000
commitccca9564b23d6f860d46ccdb86a7578e74b7a534 (patch)
tree72fbe19572d8006a0babb8782cd514bb8d05a731 /mod/search/index.php
parentcb5ecaff25b858117a57ede78f353661a520c9d4 (diff)
downloadelgg-ccca9564b23d6f860d46ccdb86a7578e74b7a534.tar.gz
elgg-ccca9564b23d6f860d46ccdb86a7578e74b7a534.tar.bz2
Fixes #2335 #2336 clean up and minor standardization of search plugin - needs html/css clean up
git-svn-id: http://code.elgg.org/elgg/trunk@8057 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/search/index.php')
-rw-r--r--mod/search/index.php24
1 files changed, 16 insertions, 8 deletions
diff --git a/mod/search/index.php b/mod/search/index.php
index 8662283e4..db2aa5cc2 100644
--- a/mod/search/index.php
+++ b/mod/search/index.php
@@ -1,9 +1,8 @@
<?php
/**
- * Elgg core search.
+ * Elgg search page
*
- * @package Elgg
- * @subpackage Core
+ * @todo much of this code should be pulled out into a library of functions
*/
// Search supports RSS
@@ -76,7 +75,7 @@ $data = htmlspecialchars(http_build_query(array(
'search_type' => 'all',
//'friends' => $friends
)));
-$url = elgg_get_site_url()."pg/search/?$data";
+$url = elgg_get_site_url() . "pg/search/?$data";
$menu_item = new ElggMenuItem('all', elgg_echo('all'), $url);
elgg_register_menu_item('page', $menu_item);
@@ -110,7 +109,7 @@ foreach ($types as $type => $subtypes) {
'friends' => $friends
)));
- $url = elgg_get_site_url()."pg/search/?$data";
+ $url = elgg_get_site_url() . "pg/search/?$data";
$menu_item = new ElggMenuItem($label, elgg_echo($label), $url);
elgg_register_menu_item('page', $menu_item);
@@ -189,7 +188,10 @@ if ($search_type == 'all' || $search_type == 'entities') {
if (is_array($results['entities']) && $results['count']) {
if ($view = search_get_search_view($current_params, 'listing')) {
- $results_html .= elgg_view($view, array('results' => $results, 'params' => $current_params));
+ $results_html .= elgg_view($view, array(
+ 'results' => $results,
+ 'params' => $current_params,
+ ));
}
}
}
@@ -207,7 +209,10 @@ if ($search_type == 'all' || $search_type == 'entities') {
if (is_array($results['entities']) && $results['count']) {
if ($view = search_get_search_view($current_params, 'listing')) {
- $results_html .= elgg_view($view, array('results' => $results, 'params' => $current_params));
+ $results_html .= elgg_view($view, array(
+ 'results' => $results,
+ 'params' => $current_params,
+ ));
}
}
}
@@ -235,7 +240,10 @@ if ($search_type != 'entities' || $search_type == 'all') {
if (is_array($results['entities']) && $results['count']) {
if ($view = search_get_search_view($current_params, 'listing')) {
- $results_html .= elgg_view($view, array('results' => $results, 'params' => $current_params));
+ $results_html .= elgg_view($view, array(
+ 'results' => $results,
+ 'params' => $current_params,
+ ));
}
}
}