mirror of
https://github.com/nxshock/simplefileshare.git
synced 2025-04-19 01:01:50 +05:00
Move script to head tag
This commit is contained in:
parent
48e439da10
commit
e7a7baa0a0
@ -7,42 +7,7 @@
|
|||||||
<title>File Storage</title>
|
<title>File Storage</title>
|
||||||
<link rel="stylesheet" href="/style.css">
|
<link rel="stylesheet" href="/style.css">
|
||||||
<link rel="icon" href="/favicon.svg" type="image/svg+xml">
|
<link rel="icon" href="/favicon.svg" type="image/svg+xml">
|
||||||
</head>
|
|
||||||
|
|
||||||
<body>
|
|
||||||
<header>
|
|
||||||
<span>
|
|
||||||
<img src="/favicon.svg">
|
|
||||||
File Storage
|
|
||||||
</span>
|
|
||||||
<label>
|
|
||||||
<input id="file-uploader" type="file">
|
|
||||||
Загрузить файл
|
|
||||||
</label>
|
|
||||||
</header>
|
|
||||||
<main>
|
|
||||||
<table>
|
|
||||||
<col width="*">
|
|
||||||
<col width="0">
|
|
||||||
<col width="0">
|
|
||||||
<tr>
|
|
||||||
<th>Имя файла</th>
|
|
||||||
<th>Размер</th>
|
|
||||||
<th>Дата</th>
|
|
||||||
</tr>
|
|
||||||
{{range .Files}} <tr>
|
|
||||||
<td><img src="/icon?ext={{.Ext}}"> <a href="/download?filename={{.Name}}">{{.Name}}</a> <a class="right" href="/stream?filename={{.Name}}">просмотр</a></td>
|
|
||||||
<td><pre>{{.Size}}</pre></td>
|
|
||||||
<td>{{.Date}}</td>
|
|
||||||
</tr>
|
|
||||||
{{end}} </table>
|
|
||||||
</main>
|
|
||||||
<footer>
|
|
||||||
Файлы хранятся как минимум {{.StorageDuration}} ч.
|
|
||||||
</footer>
|
|
||||||
</body>
|
|
||||||
|
|
||||||
</html>
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function myProgressHandler(event) {
|
function myProgressHandler(event) {
|
||||||
var p = Math.floor(event.loaded / event.total * 100);
|
var p = Math.floor(event.loaded / event.total * 100);
|
||||||
@ -69,3 +34,42 @@ document.getElementById("file-uploader").addEventListener('change', (e) => {
|
|||||||
ajax.send(formData);
|
ajax.send(formData);
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<header>
|
||||||
|
<span>
|
||||||
|
<img src="/favicon.svg">
|
||||||
|
File Storage
|
||||||
|
</span>
|
||||||
|
<label>
|
||||||
|
<input id="file-uploader" type="file">
|
||||||
|
Загрузить файл
|
||||||
|
</label>
|
||||||
|
</header>
|
||||||
|
<main>
|
||||||
|
<table>
|
||||||
|
<col width="*">
|
||||||
|
<col width="0">
|
||||||
|
<col width="0">
|
||||||
|
<tr>
|
||||||
|
<th>Имя файла</th>
|
||||||
|
<th>Размер</th>
|
||||||
|
<th>Дата</th>
|
||||||
|
</tr>
|
||||||
|
{{range .Files}} <tr>
|
||||||
|
<td><img src="/icon?ext={{.Ext}}"> <a href="/download?filename={{.Name}}">{{.Name}}</a> <a class="right" href="/stream?filename={{.Name}}">просмотр</a></td>
|
||||||
|
<td>
|
||||||
|
<pre>{{.Size}}</pre>
|
||||||
|
</td>
|
||||||
|
<td>{{.Date}}</td>
|
||||||
|
</tr>
|
||||||
|
{{end}}
|
||||||
|
</table>
|
||||||
|
</main>
|
||||||
|
<footer>
|
||||||
|
Файлы хранятся как минимум {{.StorageDuration}} ч.
|
||||||
|
</footer>
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
Loading…
x
Reference in New Issue
Block a user