fds
This commit is contained in:
parent
b5f1e08ec6
commit
5ecfb90aaa
6 changed files with 4 additions and 4 deletions
Binary file not shown.
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 40 KiB |
Binary file not shown.
Before Width: | Height: | Size: 40 KiB |
Binary file not shown.
Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 4.4 KiB |
|
@ -1057,10 +1057,10 @@ def submit_post(v):
|
||||||
|
|
||||||
url_regex = '<a href=\"(https?:\/\/[a-z]{1,20}\.[^\"]+)\" rel=\"nofollow noopener noreferrer\" target=\"_blank\">(.+)<\/a>'
|
url_regex = '<a href=\"(https?:\/\/[a-z]{1,20}\.[^\"]+)\" rel=\"nofollow noopener noreferrer\" target=\"_blank\">(.+)<\/a>'
|
||||||
for url_match in re.finditer(url_regex, new_post.body_html):
|
for url_match in re.finditer(url_regex, new_post.body_html):
|
||||||
href = url_match.group(3)
|
href = url_match.group(1)
|
||||||
if not href: continue
|
if not href: continue
|
||||||
|
|
||||||
title = url_match.group(5)
|
title = url_match.group(2)
|
||||||
if "Snapshots:\n\n" not in body: body += "Snapshots:\n\n"
|
if "Snapshots:\n\n" not in body: body += "Snapshots:\n\n"
|
||||||
|
|
||||||
if f'**[{title}]({href})**:\n\n' not in body:
|
if f'**[{title}]({href})**:\n\n' not in body:
|
||||||
|
|
|
@ -218,7 +218,7 @@
|
||||||
|
|
||||||
{% if SITE_NAME == 'Drama' %}
|
{% if SITE_NAME == 'Drama' %}
|
||||||
<a href="https://secure.transequality.org/site/Donation2?df_id=1480">
|
<a href="https://secure.transequality.org/site/Donation2?df_id=1480">
|
||||||
<img alt="site banner" src="/static/assets/images/{{SITE_NAME}}/banners/{{range(1,num_banners)|random()}}.webp?a=17" width="100%">
|
<img alt="site banner" src="/static/assets/images/{{SITE_NAME}}/banners/{{range(1,num_banners)|random()}}.webp?a=18" width="100%">
|
||||||
</a>
|
</a>
|
||||||
{% else %}
|
{% else %}
|
||||||
<a href="/">
|
<a href="/">
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<div class="col sidebar text-left d-none d-lg-block pt-3 bg-white" style="max-width:300px">
|
<div class="col sidebar text-left d-none d-lg-block pt-3 bg-white" style="max-width:300px">
|
||||||
|
|
||||||
{% set image = "/static/assets/images/" + SITE_NAME + "/sidebar/" + range(1,num_sidebar)|random()|string + ".webp?a=15" %}
|
{% set image = "/static/assets/images/" + SITE_NAME + "/sidebar/" + range(1,num_sidebar)|random()|string + ".webp?a=16" %}
|
||||||
|
|
||||||
<a role="button" data-bs-toggle="modal" data-bs-target="#expandImageModal" data-bs-url="{{image}}" onclick="expandDesktopImage('{{image}}')">
|
<a role="button" data-bs-toggle="modal" data-bs-target="#expandImageModal" data-bs-url="{{image}}" onclick="expandDesktopImage('{{image}}')">
|
||||||
<img loading="lazy" src="{{image}}" width=100%>
|
<img loading="lazy" src="{{image}}" width=100%>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue