aboutsummaryrefslogtreecommitdiff
path: root/views/default/output/tagcloud.php
diff options
context:
space:
mode:
authorben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-04-15 15:16:07 +0000
committerben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-04-15 15:16:07 +0000
commit71d39f1c4ca21bd25b9bda01451ae651cbbabb64 (patch)
tree93d67f848ed0bf60a26c57ca3c809985a8c55603 /views/default/output/tagcloud.php
parent5a6d2bf8e397792fdc557b658e5ab5caea5d9f29 (diff)
downloadelgg-71d39f1c4ca21bd25b9bda01451ae651cbbabb64.tar.gz
elgg-71d39f1c4ca21bd25b9bda01451ae651cbbabb64.tar.bz2
Tidied up output views
git-svn-id: https://code.elgg.org/elgg/trunk@463 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/output/tagcloud.php')
-rw-r--r--views/default/output/tagcloud.php20
1 files changed, 15 insertions, 5 deletions
diff --git a/views/default/output/tagcloud.php b/views/default/output/tagcloud.php
index 5d219fd07..89b6f0371 100644
--- a/views/default/output/tagcloud.php
+++ b/views/default/output/tagcloud.php
@@ -1,9 +1,19 @@
<?php
- /**
- * This is a generic view that will display a tag cloud for any
- * section; photos, services, resources and a user or group
- **/
+ /**
+ * Elgg tagcloud
+ * Displays a tagcloud
+ *
+ * @package Elgg
+ * @subpackage Core
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd
+ * @copyright Curverider Ltd 2008
+ * @link http://elgg.org/
+ *
+ * @uses $vars['tagcloud'] An array of stdClass objects with two elements: 'tag' (the text of the tag) and 'total' (the number of elements with this tag)
+ *
+ */
if (!empty($vars['tagcloud']) && is_array($vars['tagcloud'])) {
@@ -19,7 +29,7 @@
if (!empty($cloud)) $cloud .= ", ";
$size = round((log($tag->total) / log($max)) * 100) + 30;
if ($size < 60) $size = 60;
- $cloud .= "<a href=\"" . $vars['url'] . "search/?tag=". urlencode($tag->tag) . "&type=".urlencode($tag->tag_type)."\" style=\"font-size: {$size}%\" title=\"".addslashes($tag->tag)." ({$tag->total})\" style=\"text-decoration:none;\">" .$tag->tag . "</a>";
+ $cloud .= "<a href=\"" . $vars['url'] . "search/?tag=". urlencode($tag->tag) . "\" style=\"font-size: {$size}%\" title=\"".addslashes($tag->tag)." ({$tag->total})\" style=\"text-decoration:none;\">" .$tag->tag . "</a>";
}
echo $cloud;