Update
This commit is contained in:
@@ -11,7 +11,6 @@ param = False
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
form = cgi.FieldStorage(encoding='utf8')
|
form = cgi.FieldStorage(encoding='utf8')
|
||||||
# nehm die Sachen aus create und bau sie in einen Post :)
|
|
||||||
title = form.getvalue('title')
|
title = form.getvalue('title')
|
||||||
content = form.getvalue('content')
|
content = form.getvalue('content')
|
||||||
tags = form.getvalue('tags')[1:].split("#")
|
tags = form.getvalue('tags')[1:].split("#")
|
||||||
@@ -21,7 +20,7 @@ try:
|
|||||||
nicetime = strftime("%A, %d.%B %Y %H:%M Uhr")
|
nicetime = strftime("%A, %d.%B %Y %H:%M Uhr")
|
||||||
file_content = {
|
file_content = {
|
||||||
"title": title,
|
"title": title,
|
||||||
"prettytime": nicetime, #das ist nicht unbedingt sinnvoll, aber mir gefällts.
|
"prettytime": nicetime,
|
||||||
"content" : content,
|
"content" : content,
|
||||||
"tags" : tags
|
"tags" : tags
|
||||||
}
|
}
|
||||||
@@ -34,6 +33,6 @@ try:
|
|||||||
except:
|
except:
|
||||||
print("Content-type: text/html\n")
|
print("Content-type: text/html\n")
|
||||||
if not(param):
|
if not(param):
|
||||||
print("Nothing here. You reached the end of the Internet. Turn back. H.P. Backster. Hyper, Hyper.")
|
print("Nothing to see here")
|
||||||
else:
|
else:
|
||||||
print("Feeehhhleeeerrrr")
|
print("Error")
|
||||||
|
@@ -48,5 +48,5 @@ else:
|
|||||||
|
|
||||||
print()
|
print()
|
||||||
print('<a href="posts-show.py">Alle Posts!</a><br>')
|
print('<a href="posts-show.py">Alle Posts!</a><br>')
|
||||||
print('<a href="tags-show.py">Falls du noch nicht alle Tags siehst ist dies nach diesem Klick der Fall!</a><br>')
|
print('<a href="tags-show.py">Alle Tags anzeigen.</a><br>')
|
||||||
print('<a href="posts-create.py">Neuen Post verfassen!</a>')
|
print('<a href="posts-create.py">Neuen Post verfassen!</a>')
|
||||||
|
Reference in New Issue
Block a user