mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Open links in new tab in the webadmin
This commit is contained in:
parent
f47352df88
commit
b443caf63a
1 changed files with 3 additions and 0 deletions
|
@ -480,6 +480,9 @@ class Diagnoser():
|
||||||
# In cli, we remove the html tags
|
# In cli, we remove the html tags
|
||||||
if msettings.get("interface") != "api":
|
if msettings.get("interface") != "api":
|
||||||
s = html_tags.sub('', s.replace("<br>","\n"))
|
s = html_tags.sub('', s.replace("<br>","\n"))
|
||||||
|
else:
|
||||||
|
# Make it so that links open in new tabs
|
||||||
|
s = s.replace("<a href=", "<a target='_blank' rel='noopener noreferrer' href=")
|
||||||
return s
|
return s
|
||||||
|
|
||||||
item["summary"] = m18n_(item["summary"])
|
item["summary"] = m18n_(item["summary"])
|
||||||
|
|
Loading…
Add table
Reference in a new issue