aboutsummaryrefslogtreecommitdiff
path: root/mod/file/views
diff options
context:
space:
mode:
authorpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-15 18:07:38 +0000
committerpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-15 18:07:38 +0000
commit451b29b0f5fef1f41b209c51b57d6362c13696a1 (patch)
tree28e45d071a26d0306dd845e9b5085149aed00f6b /mod/file/views
parentaa55192c5e2347e31a905d4e218477dd1e0ff333 (diff)
downloadelgg-451b29b0f5fef1f41b209c51b57d6362c13696a1.tar.gz
elgg-451b29b0f5fef1f41b209c51b57d6362c13696a1.tar.bz2
Updated File mod to new UI.
git-svn-id: http://code.elgg.org/elgg/trunk@5409 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/file/views')
-rw-r--r--mod/file/views/default/file/css.php161
-rw-r--r--mod/file/views/default/file/groupprofile_files.php15
-rw-r--r--mod/file/views/default/file/typecloud.php89
-rw-r--r--mod/file/views/default/file/upload.php6
-rw-r--r--mod/file/views/default/object/file.php32
5 files changed, 127 insertions, 176 deletions
diff --git a/mod/file/views/default/file/css.php b/mod/file/views/default/file/css.php
index 64642d9de..d6f94b61d 100644
--- a/mod/file/views/default/file/css.php
+++ b/mod/file/views/default/file/css.php
@@ -9,8 +9,67 @@
* @link http://elgg.org/
*/
?>
+.files .entity_listing .entity_listing_info {
+ width:453px;
+}
+.files .entity_listing:hover {
+ background-color: white;
+}
+
+
+
+/* files - gallery view */
+.entity_gallery_item .filerepo_gallery_item {
+ margin:10px 10px 0 0;
+ padding:5px;
+ text-align:center;
+ background-color: #eeeeee;
+ -webkit-border-radius: 6px;
+ -moz-border-radius: 6px;
+ width:165px;
+}
+.entity_gallery_item .filerepo_gallery_item:hover {
+ background-color: #333333;
+}
+.filerepo_download,
+.filerepo_controls {
+ padding:0 0 1px 0;
+ margin:0 0 10px 0;
+}
+.entity_gallery .filerepo_title {
+ font-weight: bold;
+ line-height: 1.1em;
+ margin:0 0 10px 0;
+}
+.filerepo_gallery_item p {
+ margin:0;
+ padding:0;
+}
+.filerepo_gallery_item .filerepo_controls {
+ margin-top:10px;
+}
+.filerepo_gallery_item .filerepo_controls a {
+ padding-right:10px;
+ padding-left:10px;
+}
+.entity_gallery .filerepo_comments {
+ font-size:90%;
+}
+.filerepo_user_gallery_link {
+ float:right;
+ margin:5px 5px 5px 50px;
+}
+.filerepo_user_gallery_link a {
+ padding:2px 25px 5px 0;
+ background: transparent url(<?php echo $vars['url']; ?>_graphics/icon_gallery.gif) no-repeat right top;
+ display:block;
+}
+.filerepo_user_gallery_link a:hover {
+ background-position: right -40px;
+}
+/*
p.filerepo_owner {
margin:0;
padding:0;
@@ -47,8 +106,10 @@ p.filerepo_owner {
color:white;
text-decoration: none;
}
+*/
/* FILE REPRO WIDGET VIEW */
+/*
.filerepo_widget_singleitem {
margin:0 0 5px 0;
padding:5px;
@@ -97,8 +158,10 @@ p.filerepo_owner {
margin:0 10px 0 10px;
background: none;
}
+*/
/* widget gallery view */
+/*
#filerepo_widget_layout .filerepo_widget_galleryview {
-webkit-border-radius: 8px;
-moz-border-radius: 8px;
@@ -113,59 +176,10 @@ p.filerepo_owner {
.filerepo_widget_galleryview img:hover {
border:1px solid #333333;
}
+*/
-/* SINGLE ITEM VIEW */
-.filerepo_file {
- background:white;
- margin:10px 10px 0 10px;
- -webkit-border-radius: 8px;
- -moz-border-radius: 8px;
-}
-.filerepo_file .filerepo_title_owner_wrapper {
- min-height:60px;
-
-}
-.filerepo_title_owner_wrapper .filerepo_title,
-.filerepo_title_owner_wrapper .filerepo_owner {
- margin-left: 70px !important;
-}
-.filerepo_file .filerepo_maincontent {
- padding:0 20px 0 0;
-}
-.filerepo_file .filerepo_icon {
- width: 70px;
- position: absolute;
- margin:10px 0 10px 10px;
-}
-.filerepo_file .filerepo_title {
- margin:0;
- padding:7px 4px 10px 10px;
- line-height: 1.2em;
-}
-.filerepo_file .filerepo_owner {
- padding:0 0 0 10px;
-}
-.filerepo_file .filerepo_description {
- margin:10px 0 0 0;
- padding:0 0 0 10px;
-}
-.filerepo_download,
-.filerepo_controls {
- padding:0 0 1px 10px;
- margin:0 0 10px 0;
-}
-.filerepo_file .filerepo_description p {
- padding:0 0 5px 0;
- margin:0;
-}
-.filerepo_file .filerepo_specialcontent img {
- padding:10px;
- margin:0 0 0 10px;
- -webkit-border-radius: 8px;
- -moz-border-radius: 8px;
- background: black;
-}
/* zaudio player */
+/*
.filerepo_maincontent .filerepo_specialcontent {
margin:0 0 20px 0;
}
@@ -173,52 +187,9 @@ p.filerepo_owner {
padding:0 0 10px 10px;
margin:0;
}
+*/
-/* file repro gallery items */
-.search_gallery .filerepo_controls {
- padding:0;
-}
-.search_gallery .filerepo_title {
- font-weight: bold;
- line-height: 1.1em;
- margin:0 0 10px 0;
-}
-.filerepo_gallery_item {
- margin:0;
- padding:0;
- text-align:center;
-
-}
-.filerepo_gallery_item p {
- margin:0;
- padding:0;
-}
-.filerepo_gallery_item .filerepo_controls {
- margin-top:10px;
-}
-.filerepo_gallery_item .filerepo_controls a {
- padding-right:10px;
- padding-left:10px;
-}
-.search_gallery .filerepo_comments {
- font-size:90%;
-}
-
-.filerepo_user_gallery_link {
- float:right;
- margin:5px 5px 5px 50px;
-}
-.filerepo_user_gallery_link a {
- padding:2px 25px 5px 0;
- background: transparent url(<?php echo $vars['url']; ?>_graphics/icon_gallery.gif) no-repeat right top;
- display:block;
-}
-.filerepo_user_gallery_link a:hover {
- background-position: right -40px;
-}
-/* IE6 */
-* html #description_tbl { width:676px !important;}
diff --git a/mod/file/views/default/file/groupprofile_files.php b/mod/file/views/default/file/groupprofile_files.php
index 778de3301..444398522 100644
--- a/mod/file/views/default/file/groupprofile_files.php
+++ b/mod/file/views/default/file/groupprofile_files.php
@@ -1,20 +1,18 @@
<?php
- // Latest forum discussion for the group home page
+ // Files on group profile page
- //check to make sure this group forum has been activated
+ //check to make sure group files is activated
if($vars['entity']->files_enable != 'no'){
?>
<script type="text/javascript">
$(document).ready(function () {
-
-$('a.show_file_desc').click(function () {
- $(this.parentNode).children("[class=filerepo_listview_desc]").slideToggle("fast");
- return false;
-});
-
+ $('a.show_file_desc').click(function () {
+ $(this.parentNode).children("[class=filerepo_listview_desc]").slideToggle("fast");
+ return false;
+ });
}); /* end document ready function */
</script>
@@ -66,7 +64,6 @@ $('a.show_file_desc').click(function () {
}
?>
-<div class="clearfloat" /></div>
</div>
<?php
diff --git a/mod/file/views/default/file/typecloud.php b/mod/file/views/default/file/typecloud.php
index b85960849..5ac831cfe 100644
--- a/mod/file/views/default/file/typecloud.php
+++ b/mod/file/views/default/file/typecloud.php
@@ -4,64 +4,53 @@
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>
+?>
+<ul>
<?php
- $all = new stdClass;
- $all->tag = "all";
- $vars['types'][] = $all;
- $vars['types'] = array_reverse($vars['types']);
- foreach($vars['types'] as $type) {
+ $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\" ";
+ $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 {
- $class = "";
+ $owner_guid = $vars['owner_guid'];
}
-
- add_submenu_item($label, $url, 'filetypes');
-
- //echo "<li {$class} ><a href=\"{$url}\">{$label}</a></li>";
-
+ $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=\"selected\" ";
+ } else {
+ $class = "";
+ }
+
+ add_submenu_item($label, $url, 'filetypes');
+ }
+
?>
- <!-- </p> -->
- </ul>
- </div>
+</ul>
<?php
diff --git a/mod/file/views/default/file/upload.php b/mod/file/views/default/file/upload.php
index 5a1f5c927..065b0eb3f 100644
--- a/mod/file/views/default/file/upload.php
+++ b/mod/file/views/default/file/upload.php
@@ -41,8 +41,7 @@
?>
-<div class="contentWrapper">
-<form action="<?php echo $vars['url']; ?>action/<?php echo $action; ?>" enctype="multipart/form-data" method="post">
+<form action="<?php echo $vars['url']; ?>action/<?php echo $action; ?>" enctype="multipart/form-data" method="post" class="margin_top">
<p>
<label>
<?php
@@ -130,5 +129,4 @@
<input type="submit" value="<?php echo elgg_echo("save"); ?>" />
</p>
-</form>
-</div>
+</form> \ No newline at end of file
diff --git a/mod/file/views/default/object/file.php b/mod/file/views/default/object/file.php
index 9568074b2..da555772d 100644
--- a/mod/file/views/default/object/file.php
+++ b/mod/file/views/default/object/file.php
@@ -28,21 +28,21 @@
if (get_context() == "search") { // Start search listing version
if (get_input('search_viewtype') == "gallery") {
- echo "<div class=\"filerepo_gallery_item\">";
+ echo "<div class='filerepo_gallery_item'>";
if ($vars['entity']->smallthumb) {
- echo "<p class=\"filerepo_title\">" . $file->title . "</p>";
+ echo "<p class='filerepo_title'>" . $file->title . "</p>";
echo "<p><a href=\"{$file->getURL()}\"><img src=\"{$vars['url']}mod/file/thumbnail.php?size=medium&file_guid={$vars['entity']->getGUID()}\" border=\"0\" /></a></p>";
- echo "<p class=\"filerepo_timestamp\"><small><a href=\"{$vars['url']}pg/file/{$owner->username}\">{$owner->username}</a> {$friendlytime}</small></p>";
+ echo "<p class='filerepo_timestamp'><small><a href=\"{$vars['url']}pg/file/{$owner->username}\">{$owner->username}</a> {$friendlytime}</small></p>";
//get the number of comments
$numcomments = elgg_count_comments($vars['entity']);
if ($numcomments)
- echo "<p class=\"filerepo_comments\"><a href=\"{$file->getURL()}\">" . sprintf(elgg_echo("comments")) . " (" . $numcomments . ")</a></p>";
+ echo "<p class='filerepo_comments'><a href=\"{$file->getURL()}\">" . sprintf(elgg_echo("comments")) . " (" . $numcomments . ")</a></p>";
//if the user can edit, display edit and delete links
if ($file->canEdit()) {
- echo "<div class=\"filerepo_controls\"><p>";
+ echo "<div class='filerepo_controls'><p>";
echo "<a href=\"{$vars['url']}mod/file/edit.php?file_guid={$file->getGUID()}\">" . elgg_echo('edit') . "</a>&nbsp;";
echo elgg_view('output/confirmlink',array(
@@ -57,36 +57,32 @@
} else {
- echo "<p class=\"filerepo_title\">{$title}</p>";
+ echo "<p class='filerepo_title'>{$title}</p>";
echo "<a href=\"{$file->getURL()}\">" . elgg_view("file/icon", array("mimetype" => $mime, 'thumbnail' => $file->thumbnail, 'file_guid' => $file_guid, 'size' => 'large')) . "</a>";
- echo "<p class=\"filerepo_timestamp\"><small><a href=\"{$vars['url']}pg/file/{$owner->username}\">{$owner->name}</a> {$friendlytime}</small></p>";
+ echo "<p class='filerepo_timestamp'><small><a href=\"{$vars['url']}pg/file/{$owner->username}\">{$owner->name}</a> {$friendlytime}</small></p>";
//get the number of comments
$numcomments = elgg_count_comments($file);
if ($numcomments)
- echo "<p class=\"filerepo_comments\"><a href=\"{$file->getURL()}\">" . sprintf(elgg_echo("comments")) . " (" . $numcomments . ")</a></p>";
-
+ echo "<p class='filerepo_comments'><a href=\"{$file->getURL()}\">" . sprintf(elgg_echo("comments")) . " (" . $numcomments . ")</a></p>";
}
echo "</div>";
- // echo elgg_view("search/gallery",array('info' => $info, 'icon' => $icon));
} else {
- $info = "<p> <a href=\"{$file->getURL()}\">{$title}</a></p>";
- $info .= "<p class=\"owner_timestamp\"><a href=\"{$vars['url']}pg/file/{$owner->username}\">{$owner->name}</a> {$friendlytime}";
+ $info = "<p class='entity_title'> <a href=\"{$file->getURL()}\">{$title}</a></p>";
+ $info .= "<p class='entity_subtext'><a href=\"{$vars['url']}pg/file/{$owner->username}\">{$owner->name}</a> {$friendlytime}";
$numcomments = elgg_count_comments($file);
if ($numcomments)
$info .= ", <a href=\"{$file->getURL()}\">" . sprintf(elgg_echo("comments")) . " (" . $numcomments . ")</a>";
$info .= "</p>";
-
- // $icon = elgg_view("profile/icon",array('entity' => $owner, 'size' => 'small'));
$icon = "<a href=\"{$file->getURL()}\">" . elgg_view("file/icon", array("mimetype" => $mime, 'thumbnail' => $file->thumbnail, 'file_guid' => $file_guid, 'size' => 'small')) . "</a>";
echo elgg_view_listing($icon, $info);
}
- } else { // Start main version
+ } else { // Start main version
?>
<div class="filerepo_file">
@@ -151,14 +147,14 @@
</div>
<?php
if (elgg_view_exists('file/specialcontent/' . $mime)) {
- echo "<div class=\"filerepo_specialcontent\">".elgg_view('file/specialcontent/' . $mime, $vars)."</div>";
+ echo "<div class='filerepo_specialcontent'>".elgg_view('file/specialcontent/' . $mime, $vars)."</div>";
} else if (elgg_view_exists("file/specialcontent/" . substr($mime,0,strpos($mime,'/')) . "/default")) {
- echo "<div class=\"filerepo_specialcontent\">".elgg_view("file/specialcontent/" . substr($mime,0,strpos($mime,'/')) . "/default", $vars)."</div>";
+ echo "<div class='filerepo_specialcontent'>".elgg_view("file/specialcontent/" . substr($mime,0,strpos($mime,'/')) . "/default", $vars)."</div>";
}
?>
- <div class="filerepo_download"><p><a href="<?php echo $vars['url']; ?>mod/file/download.php?file_guid=<?php echo $file_guid; ?>"><?php echo elgg_echo("file:download"); ?></a></p></div>
+ <div class="filerepo_download"><p><a class="action_button small" href="<?php echo $vars['url']; ?>mod/file/download.php?file_guid=<?php echo $file_guid; ?>"><?php echo elgg_echo("file:download"); ?></a></p></div>
<?php