Set max length for comments

master
trémeur 1 month ago
parent 2c2244e401
commit c075c2f0f7

@ -65,7 +65,7 @@ def commentpage(ficno,directory,local=False):
headerfooter.headerwrite(commentspath + "/index.html","Comments for fic no. " + ficnostring,"Comments for fic no. <span id=\"ficno\">" + ficnostring + "</span>","",False,local) headerfooter.headerwrite(commentspath + "/index.html","Comments for fic no. " + ficnostring,"Comments for fic no. <span id=\"ficno\">" + ficnostring + "</span>","",False,local)
filewrite = open(commentspath + "/index.html", "a") filewrite = open(commentspath + "/index.html", "a")
if fffandom or timeelapsed.days < 730: if fffandom or timeelapsed.days < 730:
filewrite.write("<h2>Leave a comment</h2>\n<noscript>\n<p><b>JavaScript is unavailable.</b> Please <a href=\"mailto:tre@praze.net\">email me</a> any comments.</p>\n</noscript>\n<p class=\"jsonly\">Comments will be posted manually; please expect a delay between submitting your comment and seeing it below!</p>\n<form id=\"theform\" onsubmit=\"sendContact(event)\" class=\"jsonly\">\n<input type=\"text\" id=\"nameInput\" required placeholder=\"Pseudonym (required)\">\n<input type=\"email\" id=\"emailInput\" placeholder=\"Email (if you want email notification of reply)\">\n<input type=\"text\" id=\"siteInput\" placeholder=\"Site (if you want a link back)\">\n<textarea id=\"messageInput\" rows=\"5\" required placeholder=\"Your comment (required, include whatever markup [or down] you like)\"></textarea>\n<button type=\"submit\">Submit</button>\n</form>\n") filewrite.write("<h2>Leave a comment</h2>\n<noscript>\n<p><b>JavaScript is unavailable.</b> Please <a href=\"mailto:tre@praze.net\">email me</a> any comments.</p>\n</noscript>\n<p class=\"jsonly\">Comments will be posted manually; please expect a delay between submitting your comment and seeing it below!</p>\n<form id=\"theform\" onsubmit=\"sendContact(event)\" class=\"jsonly\">\n<input type=\"text\" id=\"nameInput\" required placeholder=\"Pseudonym (required)\">\n<input type=\"email\" id=\"emailInput\" placeholder=\"Email (if you want email notification of reply)\">\n<input type=\"text\" id=\"siteInput\" placeholder=\"Site (if you want a link back)\">\n<textarea id=\"messageInput\" rows=\"5\" maxlength=\"4800\" required placeholder=\"Your comment (required, include whatever markup [or down] you like)\"></textarea>\n<button type=\"submit\">Submit</button>\n</form>\n")
else: else:
try: try:
if fileread.event == "ao3exchange" and (fileread.datewords[0])["date"].year > 2019: if fileread.event == "ao3exchange" and (fileread.datewords[0])["date"].year > 2019:

Loading…
Cancel
Save