aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/templates/file_info.html
diff options
context:
space:
mode:
authorHsiangNianian <i@jyunko.cn>2024-08-16 15:23:07 +0800
committerHsiangNianian <i@jyunko.cn>2024-08-16 15:23:07 +0800
commitee281cb6ef11b8e115e02032a7c899927d2e92e5 (patch)
treeec83b3b57920b181c6c988bc6901a3730f725506 /templates/file_info.html
parent0817897398dd3ef7f0738838b20cc6c1e67db323 (diff)
downloadfiles-ee281cb6ef11b8e115e02032a7c899927d2e92e5.tar.gz
files-ee281cb6ef11b8e115e02032a7c899927d2e92e5.zip
chore: init project
Diffstat (limited to 'templates/file_info.html')
-rw-r--r--templates/file_info.html25
1 files changed, 25 insertions, 0 deletions
diff --git a/templates/file_info.html b/templates/file_info.html
new file mode 100644
index 0000000..9e88c64
--- /dev/null
+++ b/templates/file_info.html
@@ -0,0 +1,25 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+ <meta charset="UTF-8">
+ <title>File Info</title>
+</head>
+<body>
+ <h1>File Info: {{ filename }}</h1>
+ {% if file_type == 'image' %}
+ <img src="{{ url_for('download_file', filename=filename) }}" alt="{{ filename }}">
+ {% elif file_type == 'text' %}
+ <iframe src="{{ url_for('download_file', filename=filename) }}" width="100%" height="600px"></iframe>
+ {% elif file_type == 'zip' %}
+ <h2>Contents of {{ filename }}:</h2>
+ <ul>
+ {% for item in zip_contents %}
+ <li>{{ item }}</li>
+ {% endfor %}
+ </ul>
+ {% else %}
+ <p>Cannot display this file type.</p>
+ {% endif %}
+ <a href="{{ url_for('uploaded_files') }}">Back to files</a>
+</body>
+</html> \ No newline at end of file