aboutsummaryrefslogtreecommitdiff
path: root/mod/file/views/default
diff options
context:
space:
mode:
authoricewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-04-30 12:14:22 +0000
committericewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-04-30 12:14:22 +0000
commitc1f8c6378f37e2cac408731b07008a345c3ced8f (patch)
tree9073a80688d489f56fa2240f9274598d1ab58d32 /mod/file/views/default
parentc0412aa41a1efe0be21bdd6807280b6a55005053 (diff)
downloadelgg-c1f8c6378f37e2cac408731b07008a345c3ced8f.tar.gz
elgg-c1f8c6378f37e2cac408731b07008a345c3ced8f.tar.bz2
Marcus Povey <marcus@dushka.co.uk>
* First draft file upload git-svn-id: https://code.elgg.org/elgg/trunk@578 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/file/views/default')
-rw-r--r--mod/file/views/default/file/file.php36
-rw-r--r--mod/file/views/default/file/footer.php3
-rw-r--r--mod/file/views/default/file/upload.php25
3 files changed, 64 insertions, 0 deletions
diff --git a/mod/file/views/default/file/file.php b/mod/file/views/default/file/file.php
new file mode 100644
index 000000000..1b2beae53
--- /dev/null
+++ b/mod/file/views/default/file/file.php
@@ -0,0 +1,36 @@
+<?php
+ /**
+ * Elgg file browser.
+ * File renderer.
+ *
+ * @package ElggFile
+ * @author Marcus Povey
+ * @copyright Curverider Ltd 2008
+ * @link http://elgg.com/
+ */
+
+ global $CONFIG;
+
+ $tags = $vars['tags'];
+ $title = $vars['title'];
+ $desc = $vars['description'];
+
+?>
+<div class="file">
+ <table width="100%">
+ <tr>
+ <td valign="top">
+ <div class="file_icon">
+ </div>
+ </td>
+ <td valign="top">
+ <div class="title"><?php echo $title; ?></div>
+ <div class="description"><?php echo $desc; ?></div>
+ <div class="tags"><?php
+ foreach ($tags as $tag)
+ echo "<a href=\"" . $CONFIG->wwwroot . "pg/file/". $_SESSION['user']->username . "/world/?tag=$tag\">$tag</a> ";
+ ?></div>
+ </td>
+ </tr>
+ </table>
+</div>
diff --git a/mod/file/views/default/file/footer.php b/mod/file/views/default/file/footer.php
new file mode 100644
index 000000000..15c5adc7f
--- /dev/null
+++ b/mod/file/views/default/file/footer.php
@@ -0,0 +1,3 @@
+<?php
+
+?> \ No newline at end of file
diff --git a/mod/file/views/default/file/upload.php b/mod/file/views/default/file/upload.php
new file mode 100644
index 000000000..d318b85a3
--- /dev/null
+++ b/mod/file/views/default/file/upload.php
@@ -0,0 +1,25 @@
+<?php
+ /**
+ * Elgg file browser uploader
+ *
+ * @package ElggFile
+ * @author Marcus Povey
+ * @copyright Curverider Ltd 2008
+ * @link http://elgg.com/
+ */
+
+ global $CONFIG;
+
+?>
+<form action="<?php echo $vars['url']; ?>action/file/upload" enctype="multipart/form-data" method="post">
+
+ <table>
+ <tr><td><?php echo elgg_echo("file:file");?>:</td><td><div id="file"><input type="file" name="upload" /></div></td></tr>
+ <tr><td><?php echo elgg_echo("file:title");?>:</td><td><div id="title"><input type="text" name="title" size="49" /></div></td></tr>
+ <tr><td valign="top"><?php echo elgg_echo("file:desc");?>:</td><td><div id="description"><textarea name="description" cols="50" rows="10"></textarea></div></td></tr>
+ <tr><td valign="top"><?php echo elgg_echo("file:tags");?>:</td><td><div id="tags"><textarea name="tags" cols="50"></textarea></div></td></tr>
+ </table>
+
+ <input type="submit" name="Upload" value="Upload" />
+
+</form> \ No newline at end of file