From 4711091be04584cdab4060a6ff4e0bea03bc00e9 Mon Sep 17 00:00:00 2001 From: ben Date: Wed, 28 May 2008 14:30:23 +0000 Subject: Subtypes and object types for search. git-svn-id: https://code.elgg.org/elgg/trunk@742 36083f99-b078-4883-b0ff-0f9b5a30f544 --- views/default/output/tagcloud.php | 13 ++++++++++++- views/default/output/tags.php | 15 +++++++++++++-- 2 files changed, 25 insertions(+), 3 deletions(-) (limited to 'views/default') diff --git a/views/default/output/tagcloud.php b/views/default/output/tagcloud.php index 89b6f0371..8abdd715d 100644 --- a/views/default/output/tagcloud.php +++ b/views/default/output/tagcloud.php @@ -15,6 +15,17 @@ * */ + if (!empty($vars['subtype'])) { + $subtype = "&subtype=" . urlencode($vars['subtype']); + } else { + $subtype = ""; + } + if (!empty($vars['object'])) { + $object = "&object=" . urlencode($vars['object']); + } else { + $object = ""; + } + if (!empty($vars['tagcloud']) && is_array($vars['tagcloud'])) { $counter = 0; @@ -29,7 +40,7 @@ if (!empty($cloud)) $cloud .= ", "; $size = round((log($tag->total) / log($max)) * 100) + 30; if ($size < 60) $size = 60; - $cloud .= "tag)." ({$tag->total})\" style=\"text-decoration:none;\">" .$tag->tag . ""; + $cloud .= "tag)." ({$tag->total})\" style=\"text-decoration:none;\">" .$tag->tag . ""; } echo $cloud; diff --git a/views/default/output/tags.php b/views/default/output/tags.php index d559e10b3..30edffe1f 100644 --- a/views/default/output/tags.php +++ b/views/default/output/tags.php @@ -14,9 +14,20 @@ * @link http://elgg.org/ * * @uses $vars['tags'] The tags to display - * + * @uses $vars['tagtype'] The tagtype, optionally */ + if (!empty($vars['subtype'])) { + $subtype = "&subtype=" . urlencode($vars['subtype']); + } else { + $subtype = ""; + } + if (!empty($vars['object'])) { + $object = "&object=" . urlencode($vars['object']); + } else { + $object = ""; + } + if (empty($vars['tags']) && !empty($vars['value'])) $vars['tags'] = $vars['value']; if (!empty($vars['tags'])) { @@ -35,7 +46,7 @@ $type = ""; } if (is_string($tag)) { - $tagstr .= "{$tag}"; + $tagstr .= "{$tag}"; } } echo $tagstr; -- cgit v1.2.3