This commit is contained in:
Kovid Goyal 2025-03-06 22:19:04 +05:30
parent 5cf5cf04de
commit f7aeb7b490
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
2 changed files with 2 additions and 2 deletions

View File

@ -120,7 +120,7 @@ def process_web_node(node):
def load_article_from_web_json(raw):
# open('/t/raw.json', 'w').write(raw)
body = ''
data = json.loads(raw)['props']['pageProps']['cp2Content']
data = json.loads(raw)['props']['pageProps']['content']
body += f'<div style="color: red; font-size:small; font-weight:bold;">{data.get("flyTitle", "")}</div>'
body += f'<h1>{data["headline"]}</h1>'
if data.get('rubric') and data.get('rubric') is not None:

View File

@ -120,7 +120,7 @@ def process_web_node(node):
def load_article_from_web_json(raw):
# open('/t/raw.json', 'w').write(raw)
body = ''
data = json.loads(raw)['props']['pageProps']['cp2Content']
data = json.loads(raw)['props']['pageProps']['content']
body += f'<div style="color: red; font-size:small; font-weight:bold;">{data.get("flyTitle", "")}</div>'
body += f'<h1>{data["headline"]}</h1>'
if data.get('rubric') and data.get('rubric') is not None: