Update jar
This commit is contained in:
parent
8b06ea67dd
commit
0894614b03
|
|
@ -6,6 +6,7 @@ import com.github.catvod.bean.Result;
|
||||||
import com.github.catvod.bean.Vod;
|
import com.github.catvod.bean.Vod;
|
||||||
import com.github.catvod.net.OkHttp;
|
import com.github.catvod.net.OkHttp;
|
||||||
import com.github.catvod.utils.Utils;
|
import com.github.catvod.utils.Utils;
|
||||||
|
|
||||||
import org.jsoup.Jsoup;
|
import org.jsoup.Jsoup;
|
||||||
import org.jsoup.nodes.Element;
|
import org.jsoup.nodes.Element;
|
||||||
import org.jsoup.select.Elements;
|
import org.jsoup.select.Elements;
|
||||||
|
|
@ -27,7 +28,7 @@ public class TuGou extends Ali {
|
||||||
header.put("User-Agent", Utils.CHROME);
|
header.put("User-Agent", Utils.CHROME);
|
||||||
header.put("Host", "tugousou.com");
|
header.put("Host", "tugousou.com");
|
||||||
header.put("Origin", URL);
|
header.put("Origin", URL);
|
||||||
header.put("Referer", URL+"/");
|
header.put("Referer", URL + "/");
|
||||||
return header;
|
return header;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -40,12 +41,10 @@ public class TuGou extends Ali {
|
||||||
public String searchContent(String key, boolean quick) {
|
public String searchContent(String key, boolean quick) {
|
||||||
Map<String, String> params = new HashMap<>();
|
Map<String, String> params = new HashMap<>();
|
||||||
params.put("keyword", key);
|
params.put("keyword", key);
|
||||||
String searchUrl = URL + "/search";
|
String html = OkHttp.post(URL + "/search", params, getHeader());
|
||||||
String html = OkHttp.post(searchUrl, params, getHeader());
|
|
||||||
Element container = Jsoup.parse(html).select(".layui-container").get(1);
|
Element container = Jsoup.parse(html).select(".layui-container").get(1);
|
||||||
Elements aElements = container.select("p[class=layui-font-16] > a");
|
Elements aElements = container.select("p[class=layui-font-16] > a");
|
||||||
Elements pElements = container.select("p[class=layui-font-14 layui-font-gray text-align-right]");
|
Elements pElements = container.select("p[class=layui-font-14 layui-font-gray text-align-right]");
|
||||||
|
|
||||||
List<Vod> list = new ArrayList<>();
|
List<Vod> list = new ArrayList<>();
|
||||||
for (int i = 0; i < aElements.size(); i++) {
|
for (int i = 0; i < aElements.size(); i++) {
|
||||||
Element item = aElements.get(i);
|
Element item = aElements.get(i);
|
||||||
|
|
|
||||||
Binary file not shown.
|
|
@ -1 +1 @@
|
||||||
5c42e2f85ec3f05bfd281e4fcf40468a
|
630997f2d36dde4644f99300f559ff68
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue