This commit is contained in:
parent
a4f9bd7727
commit
9f20c461e4
@ -34,7 +34,7 @@ UPLOAD_PAGE = """
|
|||||||
<meta name="viewport" content="width=device-width, initial-scale=0.9">
|
<meta name="viewport" content="width=device-width, initial-scale=0.9">
|
||||||
<title>RUpload 1.33.7</title>
|
<title>RUpload 1.33.7</title>
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
font-family: "Courier New", Courier, monospace;
|
font-family: "Courier New", Courier, monospace;
|
||||||
background-color: #111111;
|
background-color: #111111;
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -121,6 +121,7 @@ UPLOAD_PAGE = """
|
|||||||
object-fit: cover;
|
object-fit: cover;
|
||||||
margin: 3px;
|
margin: 3px;
|
||||||
float:left;
|
float:left;
|
||||||
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
@ -193,7 +194,7 @@ def create_images_html(url, image_paths):
|
|||||||
images_html = ""
|
images_html = ""
|
||||||
for image_path in image_paths:
|
for image_path in image_paths:
|
||||||
path = url.rstrip("/") + "/" + image_path.name
|
path = url.rstrip("/") + "/" + image_path.name
|
||||||
images_html += f'<a href="{path}"><img class="thumbnail" src="{path}" alt="{image_path.name}" /></a>\n'
|
images_html += f'<a href="{path}"><img class="thumbnail" src="{path}" alt="{image_path.name}" /></a>\n'
|
||||||
return images_html
|
return images_html
|
||||||
|
|
||||||
|
|
||||||
@ -303,6 +304,7 @@ def create_app(
|
|||||||
web.get("/", handle_index),
|
web.get("/", handle_index),
|
||||||
web.post("/upload", handle_upload),
|
web.post("/upload", handle_upload),
|
||||||
web.static("/", upload_path),
|
web.static("/", upload_path),
|
||||||
|
web.static("/uploads", upload_path),
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
return app
|
return app
|
||||||
|
Loading…
Reference in New Issue
Block a user