From 46e131fdadd94910c0e258aa4e855ad8019edbf7 Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Mon, 7 Feb 2022 16:16:57 +0100 Subject: [mod] result_templates/videos.html: replace embedded HTML by data_src Embedded HTML breaks SearXNG architecture. To modularize, HTML is generated in the templates (oscar & simple) and result parameter 'embedded' is replaced by 'data_src', an URL for embedded content (' -) - # do search-request def request(query, params): @@ -54,7 +48,6 @@ def response(resp): title = result['name'] thumbnail = result['pictures']['sizes'][-1]['link'] publishedDate = parser.parse(result['created_time']) - embedded = embedded_url.format(videoid=videoid) # append result results.append( @@ -64,7 +57,7 @@ def response(resp): 'content': '', 'template': 'videos.html', 'publishedDate': publishedDate, - 'embedded': embedded, + 'data_src': "https://player.vimeo.com/video/" + videoid, 'thumbnail': thumbnail, } ) -- cgit v1.2.3