Browse Source

added iframe tag to cleanHTML in utilities.py

main
westernmeadow 1 year ago
parent
commit
344c654b33
2 changed files with 2 additions and 0 deletions
  1. +1
    -0
      Forums/Utilities/utilities.py
  2. +1
    -0
      MarketPlaces/Utilities/utilities.py

+ 1
- 0
Forums/Utilities/utilities.py View File

@ -419,6 +419,7 @@ def cleanHTML(driver, html):
# remove JavaScript # remove JavaScript
clean_html = re.sub(r"<script[\s\S]*?script>", "", clean_html) clean_html = re.sub(r"<script[\s\S]*?script>", "", clean_html)
clean_html = re.sub(r"<iframe[\s\S]*?iframe>", "", clean_html)
clean_html = re.sub(r"<object.*javascript[\s\S]*?object>", "", clean_html) clean_html = re.sub(r"<object.*javascript[\s\S]*?object>", "", clean_html)
clean_html = re.sub(r"<aplet.*mayscript[\s\S]*?aplet>", "", clean_html) clean_html = re.sub(r"<aplet.*mayscript[\s\S]*?aplet>", "", clean_html)
clean_html = re.sub(r"<embed.*scriptable[\s\S]*?embed>", "", clean_html) clean_html = re.sub(r"<embed.*scriptable[\s\S]*?embed>", "", clean_html)


+ 1
- 0
MarketPlaces/Utilities/utilities.py View File

@ -430,6 +430,7 @@ def cleanHTML(driver, html):
# remove JavaScript # remove JavaScript
clean_html = re.sub(r"<script[\s\S]*?script>", "", clean_html) clean_html = re.sub(r"<script[\s\S]*?script>", "", clean_html)
clean_html = re.sub(r"<iframe[\s\S]*?iframe>", "", clean_html)
clean_html = re.sub(r"<object.*javascript[\s\S]*?object>", "", clean_html) clean_html = re.sub(r"<object.*javascript[\s\S]*?object>", "", clean_html)
clean_html = re.sub(r"<aplet.*mayscript[\s\S]*?aplet>", "", clean_html) clean_html = re.sub(r"<aplet.*mayscript[\s\S]*?aplet>", "", clean_html)
clean_html = re.sub(r"<embed.*scriptable[\s\S]*?embed>", "", clean_html) clean_html = re.sub(r"<embed.*scriptable[\s\S]*?embed>", "", clean_html)


Loading…
Cancel
Save