浏览代码

[fix] habrahabr.ru xpath fix

misnyo 7 年前
父节点
当前提交
bf1ca2ccd3
共有 1 个文件被更改,包括 3 次插入3 次删除
  1. 3
    3
      searx/settings.yml

+ 3
- 3
searx/settings.yml 查看文件

@@ -333,9 +333,9 @@ engines:
333 333
     engine : xpath
334 334
     paging : True
335 335
     search_url : https://habrahabr.ru/search/page{pageno}/?q={query}
336
-    url_xpath : //div[@class="search_results"]//a[contains(@class, "post__title_link")]/@href
337
-    title_xpath : //div[@class="search_results"]//a[contains(@class, "post__title_link")]
338
-    content_xpath : //div[@class="search_results"]//div[contains(@class, "content")]
336
+    url_xpath : //article[contains(@class, "post")]//a[@class="post__title_link"]/@href
337
+    title_xpath : //article[contains(@class, "post")]//a[@class="post__title_link"]
338
+    content_xpath : //article[contains(@class, "post")]//div[contains(@class, "post__text")]
339 339
     categories : it
340 340
     timeout : 4.0
341 341
     disabled : True