-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.tmpl
22 lines (22 loc) · 944 Bytes
/
index.tmpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<html>
<head><title>UniSrv {{html .Path}}</title></head>
<body>
<form action="/upload" method="post" enctype="multipart/form-data">
<input type="file" name="file">
<input type="hidden" name="dir" value="{{html .Path}}">
<input type="submit" value="Upload">
</form>
<pre>curl -F [email protected] -F dir=hostpath/ http://{{.Host}}/upload</pre>
<hr>
<p>{{range $i, $crumb := .Breadcrumbs}}<a href="{{html $crumb.Link}}">{{html $crumb.Text}}</a>{{if ne $i 0}}/{{end}}{{end}}</p>
<table>
<tr><td><a href="..">..</a></td><td><dir></td></tr>
{{range .Items}}
<tr>
<td><a href="{{html .URL}}">{{html .Name}}</a></td>
<td> {{if .IsDir}} <dir> {{else}} {{.HumanSize}} {{end}}</td>
</tr>
{{end}}
</table>
</body>
</html>