100 dom = html.fromstring(data)
102 for item
in eval_xpath_list(dom,
"//ul[contains(@class, 'lst_total')]/li[contains(@class, 'bx')]"):
105 thumbnail = eval_xpath_getindex(item,
".//div[contains(@class, 'thumb_single')]//img/@data-lazysrc", 0)
106 except (ValueError, TypeError, SearxEngineXPathException):
111 title=extract_text(eval_xpath(item,
".//a[contains(@class, 'link_tit')]")),
112 url=eval_xpath_getindex(item,
".//a[contains(@class, 'link_tit')]/@href", 0),
113 content=extract_text(
114 eval_xpath(item,
".//div[contains(@class, 'total_dsc_wrap')]//a[contains(@class, 'api_txt_lines')]")
149 dom = html.fromstring(data)
151 for item
in eval_xpath_list(
152 dom,
"//div[contains(@class, 'sds-comps-base-layout') and contains(@class, 'sds-comps-full-layout')]"
154 title = extract_text(eval_xpath(item,
".//span[contains(@class, 'sds-comps-text-type-headline1')]/text()"))
156 url = eval_xpath_getindex(item,
".//a[@href and @nocr='1']/@href", 0)
158 content = extract_text(eval_xpath(item,
".//span[contains(@class, 'sds-comps-text-type-body1')]"))
162 thumbnail = eval_xpath_getindex(
164 ".//div[contains(@class, 'sds-comps-image') and contains(@class, 'sds-rego-thumb-overlay')]//img[@src]/@src",
167 except (ValueError, TypeError, SearxEngineXPathException):
170 if title
and content
and url:
186 dom = html.fromstring(data)
188 for item
in eval_xpath_list(dom,
"//li[contains(@class, 'video_item')]"):
189 url = eval_xpath_getindex(item,
".//a[contains(@class, 'info_title')]/@href", 0)
193 thumbnail = eval_xpath_getindex(item,
".//img[contains(@class, 'thumb')]/@src", 0)
194 except (ValueError, TypeError, SearxEngineXPathException):
199 length = parse_duration_string(extract_text(eval_xpath(item,
".//span[contains(@class, 'time')]")))
200 except (ValueError, TypeError):
205 "template":
"videos.html",
206 "title": extract_text(eval_xpath(item,
".//a[contains(@class, 'info_title')]")),
208 "thumbnail": thumbnail,
210 "iframe_src": get_embeded_stream_url(url),