aboutsummaryrefslogtreecommitdiff
path: root/views/default/output/tags.php
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-01-06 12:52:08 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2011-01-06 12:52:08 +0000
commit3a917aa158c1ef0945c8b4892eaa8f87e5fa1a1e (patch)
treee56511d288a4a332ae14b15f63e7b92d9bdc26f6 /views/default/output/tags.php
parentd219c7312b87a0a18250c0018812e34619bfde43 (diff)
downloadelgg-3a917aa158c1ef0945c8b4892eaa8f87e5fa1a1e.tar.gz
elgg-3a917aa158c1ef0945c8b4892eaa8f87e5fa1a1e.tar.bz2
changed tag display to <ul>
git-svn-id: http://code.elgg.org/elgg/trunk@7851 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/output/tags.php')
-rw-r--r--views/default/output/tags.php16
1 files changed, 8 insertions, 8 deletions
diff --git a/views/default/output/tags.php b/views/default/output/tags.php
index 1dbf14a7d..f4804e76e 100644
--- a/views/default/output/tags.php
+++ b/views/default/output/tags.php
@@ -1,7 +1,6 @@
<?php
/**
* Elgg tags
- * Displays a list of tags, separated by commas
*
* Tags can be a single string (for one tag) or an array of strings
*
@@ -9,7 +8,8 @@
* @subpackage Core
*
* @uses $vars['tags'] The tags to display
- * @uses $vars['tagtype'] The tagtype, optionally
+ * @uses $vars['type'] The entity type, optional
+ * @uses $vars['subtype'] The entity subtype, optional
*/
if (!empty($vars['subtype'])) {
@@ -28,23 +28,23 @@ if (empty($vars['tags']) && !empty($vars['value'])) {
}
if (!empty($vars['tags'])) {
- $tagstr = "";
if (!is_array($vars['tags'])) {
$vars['tags'] = array($vars['tags']);
}
+ echo '<ul class="elgg-tags">';
foreach($vars['tags'] as $tag) {
- if (!empty($tagstr)) {
- $tagstr .= ", ";
- }
if (!empty($vars['type'])) {
$type = "&type={$vars['type']}";
} else {
$type = "";
}
+ $url = elgg_get_site_url() . 'pg/search/?q=' . urlencode($tag) . "&search_type=tags{$type}{$subtype}{$object}";
if (is_string($tag)) {
- $tagstr .= "<a rel=\"tag\" href=\"".elgg_get_site_url()."pg/search/?q=".urlencode($tag) . "&search_type=tags{$type}{$subtype}{$object}\">" . htmlspecialchars($tag, ENT_QUOTES, 'UTF-8') . "</a>";
+ echo '<li>';
+ echo "<a rel=\"tag\" href=\"$url\">" . htmlspecialchars($tag, ENT_QUOTES, 'UTF-8') . "</a>";
+ echo '</li>';
}
}
- echo $tagstr;
+ echo '</ul>';
}