Skip to content

Commit

Permalink
Adding iframe attributes to attribute whitelist
Browse files Browse the repository at this point in the history
To properly show YouTube-embeds, we need to allow some attributes on `iframe` tags. I've added all attributes that are normal for such an embed, including `width` and `height` (which we may not need if we want to make the frame resize to its parent).
  • Loading branch information
SebastiaanZ authored Jan 6, 2020
1 parent aeece01 commit 86acb42
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pydis_site/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -373,6 +373,7 @@
'img': ['class', 'id', 'src', 'alt', 'width', 'height'],
'section': ['class', 'id'],
'article': ['class', 'id'],
'iframe': ['width', 'height', 'src', 'frameborder', 'allow', 'allowfullscreen'],
}

WIKI_MARKDOWN_HTML_WHITELIST = [
Expand Down

0 comments on commit 86acb42

Please sign in to comment.