client body size 100M

master
root 5 years ago
parent 601eaea199
commit bb0c41974c

@ -116,69 +116,6 @@ a.mapping:hover{
cursor: pointer;
}
/* INDEX */
h1{
color: #FFF;
font-family: "Lyon", Arial, Helvetica, sans-serif;
font-size: calc(15px + 5vw);
text-align: center;
width: 100vw;
padding-bottom: 15px;
}
#indexabout{
padding-top: 20vh;
padding-bottom: 25px;
}
dl{
font-family: "Favorit", Arial, Helvetica, sans-serif;
font-size: calc(12px + 0.3vw);
text-align: center;
width: 100vw;
font-weight: 400;
font-style: italic;
transform: scaleX(0.75);
line-height: 110%;
}
.colorbackground{
margin-top: -5px;
position: absolute;
overflow: hidden;
width: 100vw;
height: 100vh;
z-index: 1;
}
#indexyellowleft{
position: fixed;
left: 0;
top: 0;
display: inline-block;
width: 38vw;
height: 100vh;
background-color: #cfff00;
}
#indexyellowright{
position: fixed;
left: 76vw;
top: 0;
display: inline-block;
height: 100vh;
width: 24vw;
background-color: #cfff00;
}
.indextext{
position: fixed;
z-index: 2;
}
/* HEADER */
header{
@ -250,7 +187,8 @@ a.head:visited{
.scrollrequests{
overflow: auto;
height: 100%;
height: 85%;
margin-bottom: 100px;
}
.booksrequested{
@ -443,3 +381,73 @@ label{
font-family: "Favorit", Arial, Helvetica, sans-serif;
font-weight: 300;
}
.explainspace{
font-size: calc(8px + 0.25vw);
line-height: 110%;
}
/* INDEX */
h1{
color: #FFF;
font-family: "Lyon", Arial, Helvetica, sans-serif;
font-size: calc(15px + 5vw);
text-align: center;
width: 100vw;
padding-bottom: 15px;
}
#indexabout{
padding-top: 20vh;
padding-bottom: 25px;
}
dl{
font-family: "Favorit", Arial, Helvetica, sans-serif;
font-size: calc(12px + 0.3vw);
text-align: center;
width: 100vw;
font-weight: 400;
font-style: italic;
transform: scaleX(0.75);
line-height: 110%;
}
.colorbackground{
margin-top: -5px;
position: absolute;
overflow: hidden;
width: 100vw;
height: 100vh;
z-index: 1;
}
#indexyellowleft{
position: fixed;
left: 0;
top: 0;
display: inline-block;
width: 38vw;
height: 100vh;
background-color: #cfff00;
}
#indexyellowright{
position: fixed;
left: 76vw;
top: 0;
display: inline-block;
height: 100vh;
width: 24vw;
background-color: #cfff00;
}
.indextext{
position: fixed;
z-index: 2;
}
a.indexdt{
font-weight: 400;
}

@ -10,16 +10,16 @@
<div class="indextext">
<dl>
<dt id="indexabout"><a href="about">About Tactical Watermarks</a></dt>
<dt id="indexabout"><a href="about" class="indexdt">About Tactical Watermarks</a></dt>
</dl>
<h1>TACTICAL WATERMARKS</h1>
<dl>
<dt><a href="uploadbook">De-watermark and republish a title</a></dt>
<dt><a href="republish">Republish a new title</a></dt>
<dt><a href="terms">Community Guidelines</a></dt>
<dt><a href="ov73e3lxezo2klxva2frlzqbb2usiozqbe56xiochvz5lznpkk6kw4ad.onion">Link to Tor Browser</a></dt>
<dt><a href="uploadbook" class="indexdt" >De-watermark and republish a title</a></dt>
<dt><a href="republish" class="indexdt">Republish a new title</a></dt>
<dt><a href="terms" class="indexdt">Community Guidelines</a></dt>
<dt><a href="ov73e3lxezo2klxva2frlzqbb2usiozqbe56xiochvz5lznpkk6kw4ad.onion" class="indexdt">Link to Tor Browser</a></dt>
</dl>
</div>

@ -38,7 +38,7 @@ app.config["BOOK_UPLOAD_DEWATERMARK"] = "/var/www/TacticalApp/app/static/dewater
app.config["BOOK_UPLOAD_REPUBLISH"] = "/var/www/TacticalApp/app/static/republish"
app.config["BOOK_REQUEST"] = "/var/www/TacticalApp/app/static/request"
app.config["ALLOWED_BOOK_EXTENSIONS"] = ["PDF", "EPUB"]
app.config["MAX_BOOK_FILESIZE"] = 40 * 1024 * 1024
#app.config["MAX_BOOK_FILESIZE"] = 4000 * 1024 * 1024
def allowed_book(filename):
if not "." in filename:
@ -51,11 +51,11 @@ def allowed_book(filename):
else:
return False
def allowed_book_filesize(filesize):
if int(filesize) <= app.config["MAX_BOOK_FILESIZE"]:
return True
else:
return False
#def allowed_book_filesize(filesize):
# if int(filesize) <= app.config["MAX_BOOK_FILESIZE"]:
# return True
# else:
# return False
#Request a book
#REQUEST IN DEWATERMARK
@ -121,9 +121,9 @@ def uploadbook():
if request.files:
#request filesize
if not allowed_book_filesize(request.cookies.get("filesize")):
print("File exceeded maximum size")
return redirect(request.url)
#if not allowed_book_filesize(request.cookies.get("filesize")):
# print("File exceeded maximum size")
# return redirect(request.url)
#demand checkbox
if not request.form.get('match-with-pairs'):
@ -188,9 +188,9 @@ def republish():
if request.files:
#request filesize
if not allowed_book_filesize(request.cookies.get("filesize")):
print("File exceeded maximum size")
return redirect(request.url)
#if not allowed_book_filesize(request.cookies.get("filesize")):
# print("File exceeded maximum size")
# return redirect(request.url)
#demand checkbox
if not request.form.get('match-with-pairs'):

Loading…
Cancel
Save