mirror of
https://github.com/onionshare/onionshare.git
synced 2025-01-25 14:07:37 -05:00
added awesome pink skull and crossbone 404 error page
This commit is contained in:
parent
ef18336520
commit
066b0239ee
15
404.html
Normal file
15
404.html
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>Error 404</title>
|
||||||
|
<style type="text/css">
|
||||||
|
body {
|
||||||
|
background-color: #FFC4D5;
|
||||||
|
color: #FF0048;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 30em;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
</head>
|
||||||
|
<body>☠</body>
|
||||||
|
</html>
|
@ -31,6 +31,10 @@ def download():
|
|||||||
basename = os.path.basename(filename)
|
basename = os.path.basename(filename)
|
||||||
return send_from_directory(dirname, basename, as_attachment=True)
|
return send_from_directory(dirname, basename, as_attachment=True)
|
||||||
|
|
||||||
|
@app.errorhandler(404)
|
||||||
|
def page_not_found(e):
|
||||||
|
return render_template_string(open('{0}/404.html'.format(os.path.dirname(__file__))).read())
|
||||||
|
|
||||||
def get_platform():
|
def get_platform():
|
||||||
if 'ONIONSHARE_PLATFORM' in os.environ:
|
if 'ONIONSHARE_PLATFORM' in os.environ:
|
||||||
return os.environ['ONIONSHARE_PLATFORM']
|
return os.environ['ONIONSHARE_PLATFORM']
|
||||||
|
Loading…
x
Reference in New Issue
Block a user