aboutsummaryrefslogtreecommitdiff
path: root/mod/file/views/default/file/typecloud.php
diff options
context:
space:
mode:
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-03 17:53:05 +0000
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-03 17:53:05 +0000
commit4766f36a4d74924f21ff329c4318ce4e069ffa04 (patch)
tree969b84632f2a8b0db79788a8a6db8e41d63e5cb4 /mod/file/views/default/file/typecloud.php
parent57a217fd6b708844407486046a1faa23b46cac08 (diff)
downloadelgg-4766f36a4d74924f21ff329c4318ce4e069ffa04.tar.gz
elgg-4766f36a4d74924f21ff329c4318ce4e069ffa04.tar.bz2
Pulled in the interface changes.
git-svn-id: http://code.elgg.org/elgg/trunk@5257 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/file/views/default/file/typecloud.php')
-rw-r--r--mod/file/views/default/file/typecloud.php70
1 files changed, 70 insertions, 0 deletions
diff --git a/mod/file/views/default/file/typecloud.php b/mod/file/views/default/file/typecloud.php
new file mode 100644
index 000000000..b85960849
--- /dev/null
+++ b/mod/file/views/default/file/typecloud.php
@@ -0,0 +1,70 @@
+<?php
+
+ $types = $vars['types'];
+
+ if (is_array($vars['types']) && sizeof($vars['types'])) {
+
+?>
+
+ <!-- <div class="filerepo_types"> -->
+ <!-- <p><b><?php echo elgg_echo('file:types'); ?>:</b> -->
+
+ <div id="canvas_header_submenu">
+ <ul>
+<?php
+
+ $all = new stdClass;
+ $all->tag = "all";
+ $vars['types'][] = $all;
+ $vars['types'] = array_reverse($vars['types']);
+ foreach($vars['types'] as $type) {
+
+ $tag = $type->tag;
+ if ($tag != "all") {
+ $label = elgg_echo("file:type:" . $tag);
+ } else {
+ $label = elgg_echo('all');
+ }
+
+ $url = $vars['url'] . "mod/file/search.php?subtype=file";
+ if ($tag != "all")
+ $url .= "&md_type=simpletype&tag=" . urlencode($tag);
+ if (isset($vars['friend_guid']) && $vars['friend_guid'] != false) {
+ $url .= "&friends_guid={$vars['friend_guid']}";
+ } else if ($vars['owner_guid'] != "") {
+ if (is_array($vars['owner_guid'])) {
+ $owner_guid = implode(",",$vars['owner_guid']);
+ } else {
+ $owner_guid = $vars['owner_guid'];
+ }
+ $url .= "&owner_guid={$owner_guid}";
+ }
+ if ($tag == "image")
+ $url .= "&search_viewtype=gallery";
+
+ $url .= "&page_owner=" . page_owner();
+
+ $inputtag = get_input('tag');
+ if ($inputtag == $tag || (empty($inputtag) && $tag == "all")) {
+ // $class = "class=\"filerepo_types_current\"";
+ $class = " class=\"selected\" ";
+ } else {
+ $class = "";
+ }
+
+ add_submenu_item($label, $url, 'filetypes');
+
+ //echo "<li {$class} ><a href=\"{$url}\">{$label}</a></li>";
+
+ }
+
+?>
+ <!-- </p> -->
+ </ul>
+ </div>
+
+<?php
+
+ }
+
+?> \ No newline at end of file