mirror of https://gitlab.com/bashrc2/epicyon
Sandbox settings
parent
503f768b59
commit
4c93567afa
3
maps.py
3
maps.py
|
|
@ -367,7 +367,8 @@ def html_open_street_map(url: str,
|
||||||
str(longitude + bounding_box_degrees) + \
|
str(longitude + bounding_box_degrees) + \
|
||||||
'%2C' + \
|
'%2C' + \
|
||||||
str(latitude + bounding_box_degrees) + \
|
str(latitude + bounding_box_degrees) + \
|
||||||
'&layer=mapnik" style="border: 1px solid black" sandbox>' + \
|
'&layer=mapnik" style="border: 1px solid black" ' + \
|
||||||
|
'sandbox="allow-scripts allow-same-origin">' + \
|
||||||
'</iframe><br/><small><a href="' + osm_url + \
|
'</iframe><br/><small><a href="' + osm_url + \
|
||||||
'">' + translate['View Larger Map'] + '</a></small>\n'
|
'">' + translate['View Larger Map'] + '</a></small>\n'
|
||||||
return html_str
|
return html_str
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,8 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
|
||||||
channel + '&parent=' + domain + '" ' + \
|
channel + '&parent=' + domain + '" ' + \
|
||||||
'frameborder="0" allowfullscreen="true" ' + \
|
'frameborder="0" allowfullscreen="true" ' + \
|
||||||
'scrolling="no" height="' + str(height) + \
|
'scrolling="no" height="' + str(height) + \
|
||||||
'" width="' + str(width) + '" sandbox>' + \
|
'" width="' + str(width) + \
|
||||||
|
'" sandbox="allow-scripts allow-same-origin">' + \
|
||||||
'</iframe></span>\n</center>\n'
|
'</iframe></span>\n</center>\n'
|
||||||
return content
|
return content
|
||||||
|
|
||||||
|
|
@ -72,8 +73,9 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
|
||||||
"\" height=\"" + str(height) + \
|
"\" height=\"" + str(height) + \
|
||||||
"\" frameborder=\"0\" allow=\"" + \
|
"\" frameborder=\"0\" allow=\"" + \
|
||||||
"fullscreen\" allowfullscreen " + \
|
"fullscreen\" allowfullscreen " + \
|
||||||
"tabindex=\"10\" sandbox></iframe>\n" + \
|
"tabindex=\"10\" " + \
|
||||||
"</span>\n</center>\n"
|
"sandbox=\"allow-scripts allow-same-origin\">" + \
|
||||||
|
"</iframe>\n</span>\n</center>\n"
|
||||||
return content
|
return content
|
||||||
|
|
||||||
video_site = 'https://www.youtube.com'
|
video_site = 'https://www.youtube.com'
|
||||||
|
|
@ -96,7 +98,8 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
|
||||||
video_site + url + "\" width=\"" + str(width) + \
|
video_site + url + "\" width=\"" + str(width) + \
|
||||||
"\" height=\"" + str(height) + \
|
"\" height=\"" + str(height) + \
|
||||||
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
||||||
"allowfullscreen tabindex=\"10\" sandbox>" + \
|
"allowfullscreen tabindex=\"10\" " + \
|
||||||
|
"sandbox=\"allow-scripts allow-same-origin\">" + \
|
||||||
"</iframe>\n</span></center>\n"
|
"</iframe>\n</span></center>\n"
|
||||||
return content
|
return content
|
||||||
|
|
||||||
|
|
@ -119,7 +122,8 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
|
||||||
video_site + url + "\" width=\"" + str(width) + \
|
video_site + url + "\" width=\"" + str(width) + \
|
||||||
"\" height=\"" + str(height) + \
|
"\" height=\"" + str(height) + \
|
||||||
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
||||||
"allowfullscreen tabindex=\"10\" sandbox>" + \
|
"allowfullscreen tabindex=\"10\" " + \
|
||||||
|
"sandbox=\"allow-scripts allow-same-origin\">" + \
|
||||||
"</iframe>\n</span></center>\n"
|
"</iframe>\n</span></center>\n"
|
||||||
return content
|
return content
|
||||||
|
|
||||||
|
|
@ -169,8 +173,9 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
|
||||||
video_site + url + "\" width=\"" + \
|
video_site + url + "\" width=\"" + \
|
||||||
str(width) + "\" height=\"" + str(height) + \
|
str(width) + "\" height=\"" + str(height) + \
|
||||||
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
||||||
"allowfullscreen tabindex=\"10\" sandbox></iframe>\n" + \
|
"allowfullscreen tabindex=\"10\" " + \
|
||||||
"</span>\n</center>\n"
|
"sandbox=\"allow-scripts allow-same-origin\">" + \
|
||||||
|
"</iframe>\n</span>\n</center>\n"
|
||||||
return content
|
return content
|
||||||
|
|
||||||
video_site = 'https://media.ccc.de'
|
video_site = 'https://media.ccc.de'
|
||||||
|
|
@ -193,8 +198,9 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
|
||||||
video_site + url + "\" width=\"" + \
|
video_site + url + "\" width=\"" + \
|
||||||
str(width) + "\" height=\"" + str(height) + \
|
str(width) + "\" height=\"" + str(height) + \
|
||||||
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
"\" frameborder=\"0\" allow=\"fullscreen\" " + \
|
||||||
"allowfullscreen tabindex=\"10\" sandbox></iframe>\n" + \
|
"allowfullscreen tabindex=\"10\" " + \
|
||||||
"</span>\n</center>\n"
|
"sandbox=\"allow-scripts allow-same-origin\">" + \
|
||||||
|
"</iframe>\n</span>\n</center>\n"
|
||||||
return content
|
return content
|
||||||
|
|
||||||
if '"https://' in content:
|
if '"https://' in content:
|
||||||
|
|
@ -273,7 +279,8 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
|
||||||
site + url + "\" width=\"" + str(width) + \
|
site + url + "\" width=\"" + str(width) + \
|
||||||
"\" height=\"" + str(height) + \
|
"\" height=\"" + str(height) + \
|
||||||
"\" frameborder=\"0\" allow=\"" + \
|
"\" frameborder=\"0\" allow=\"" + \
|
||||||
"fullscreen\" allowfullscreen tabindex=\"10\" sandbox>" + \
|
"fullscreen\" allowfullscreen tabindex=\"10\" " + \
|
||||||
|
"sandbox=\"allow-scripts allow-same-origin\">" + \
|
||||||
"</iframe>\n</span>\n</center>\n"
|
"</iframe>\n</span>\n</center>\n"
|
||||||
return content
|
return content
|
||||||
return content
|
return content
|
||||||
|
|
|
||||||
|
|
@ -394,7 +394,9 @@ def html_podcast_episode(translate: {},
|
||||||
" <iframe loading=\"lazy\" decoding=\"async\" src=\"" + \
|
" <iframe loading=\"lazy\" decoding=\"async\" src=\"" + \
|
||||||
url + "\" width=\"400\" height=\"300\" " + \
|
url + "\" width=\"400\" height=\"300\" " + \
|
||||||
"frameborder=\"0\" allow=\"fullscreen\" " + \
|
"frameborder=\"0\" allow=\"fullscreen\" " + \
|
||||||
"allowfullscreen sandbox>\n </iframe>\n </span>\n"
|
"allowfullscreen " + \
|
||||||
|
"sandbox=\"allow-scripts allow-same-origin\">\n" + \
|
||||||
|
" </iframe>\n </span>\n"
|
||||||
elif 'video' in podcast_properties['linkMimeType']:
|
elif 'video' in podcast_properties['linkMimeType']:
|
||||||
video_mime_type = podcast_properties['linkMimeType']
|
video_mime_type = podcast_properties['linkMimeType']
|
||||||
video_msg = 'Your browser does not support the video element.'
|
video_msg = 'Your browser does not support the video element.'
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue