diff --git a/Source/Form.Comment.html b/Source/Form.Comment.html
new file mode 100644
index 0000000..533892f
--- /dev/null
+++ b/Source/Form.Comment.html
@@ -0,0 +1,5 @@
+
diff --git a/Source/Form.Main.html b/Source/Form.Main.html
new file mode 100644
index 0000000..c47fe9e
--- /dev/null
+++ b/Source/Form.Main.html
@@ -0,0 +1,26 @@
+
+
Comments
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Source/Form.html b/Source/Form.html
deleted file mode 100644
index 03b60b5..0000000
--- a/Source/Form.html
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-
-
-
-
diff --git a/Source/Style.css b/Source/Main.css
similarity index 87%
rename from Source/Style.css
rename to Source/Main.css
index faaedd8..e905e0a 100644
--- a/Source/Style.css
+++ b/Source/Main.css
@@ -1,6 +1,7 @@
Input, TextArea {
- Width: 100%;
+ //Width: 100%;
}
+/*
Span {
Display: Block;
Overflow: Hidden;
@@ -9,6 +10,7 @@ Label{
Float: Left;
Padding-Right: 8px;
}
+*/
TextArea {
Width: 100%;
Height: 30%;
diff --git a/Source/Main.html b/Source/Main.html
new file mode 100644
index 0000000..4af8db6
--- /dev/null
+++ b/Source/Main.html
@@ -0,0 +1,10 @@
+
+
+
+
+
+
+
+
diff --git a/Source/Server.py b/Source/Server.py
index a6d16a8..813f27a 100755
--- a/Source/Server.py
+++ b/Source/Server.py
@@ -42,19 +42,51 @@ def SetConfig():
Config[i] = File[i]
return Config
-def HandlePost(Req):
+def GetComments():
+ return [0,0,0]
+
+def PatchHTML():
+ Base = ReadFile('Source/Main.html')
+ FormMain = ReadFile('Source/Form.Main.html')
+ FormComment = ReadFile('Source/Form.Comment.html')
+
+ Comments = ''
+ for i in GetComments():
+ Comments += "\n
\n" + FormComment.format(
+ User="User",
+ Date="Date",
+ ID="ID")
+
+ return Base.format(FormMain + Comments)
+
+def Get(Req):
+ Data = Req.args
+ print(Data.get('Site'))
+ print(Data.get('Page'))
+ print(Data.get('User'))
+ print(Data.get('CAPTCHA'))
+ print(Data.get('Comment'))
+ print(Data.get('SecretKey'))
+ print(Data.get('Action'))
+ print(Data.get('Reply'))
+ print(Data.get('Report'))
+ return PatchHTML()
+
+def Post(Req):
Data = Req.get_json()
+ print(Data)
-@App.route('/Test.html')
-def Test():
- return send_file('Test.html')
+@App.route('/Main.css')
+def SendCSS():
+ return send_file('Main.css')
-@App.route('/Comments', methods=['GET' 'POST'])
+@App.route('/Comments', methods=['GET', 'POST'])
def Comments():
- if request.method == 'GET':
- pass
- if request.method == 'POST':
- return HandlePost(request)
+ Req = request
+ if Req.method == 'GET':
+ return Get(Req)
+ if Req.method == 'POST':
+ return Post(Req)
if __name__ == '__main__':
Config = SetConfig()