From 8f344506ba0a4f57082e279c0e98d2396b0028fd Mon Sep 17 00:00:00 2001 From: Meekdai Date: Sun, 13 Aug 2023 21:10:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E7=AB=A0=E9=A1=B5=E8=87=AA=E5=AE=9A?= =?UTF-8?q?=E4=B9=89script=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Gmeek.py | 4 ++++ templates/post.html | 3 +++ 2 files changed, 7 insertions(+) diff --git a/Gmeek.py b/Gmeek.py index 274f9ac..0a9d7f4 100644 --- a/Gmeek.py +++ b/Gmeek.py @@ -192,6 +192,10 @@ class GMEEK(): self.blogBase["postListJson"][postNum]["fontSize"]=str(postConfig["fontSize"]) else: self.blogBase["postListJson"][postNum]["fontSize"]="" + if "script" in postConfig: + self.blogBase["postListJson"][postNum]["script"]=str(postConfig["script"]) + else: + self.blogBase["postListJson"][postNum]["script"]="" thisTime=datetime.datetime.fromtimestamp(self.blogBase["postListJson"][postNum]["createdAt"]) thisYear=thisTime.year diff --git a/templates/post.html b/templates/post.html index 64d9568..f957a88 100644 --- a/templates/post.html +++ b/templates/post.html @@ -102,4 +102,7 @@ function iFrameLoading(){ } + +{{ blogBase['script'] }} + {% endblock %}