低端影视修复
This commit is contained in:
parent
470c38cea4
commit
bb00c0bdee
|
|
@ -111,18 +111,11 @@ public class Ddrk extends Cloud {
|
||||||
Document doc = Jsoup.parse(OkHttp.string(url, getHeaders(url)));
|
Document doc = Jsoup.parse(OkHttp.string(url, getHeaders(url)));
|
||||||
Elements elements = doc.select("li.menu-item a");
|
Elements elements = doc.select("li.menu-item a");
|
||||||
List<Class> classes = new ArrayList<>();
|
List<Class> classes = new ArrayList<>();
|
||||||
ArrayList<String> allClass = new ArrayList<>();
|
|
||||||
for (Element ele : elements) {
|
for (Element ele : elements) {
|
||||||
String name = ele.attr("title");
|
String name = ele.attr("title");
|
||||||
boolean show = !filter || (name.equals("热映中") || name.equals("欧美剧") || name.equals("日剧") || name.equals("韩剧") || name.equals("华语剧") || name.equals("其他地区") || name.equals("全部") || name.equals("欧美电影") || name.equals("日韩电影") || name.equals("华语电影") || name.equals("新番") || name.equals("动画") || name.equals("纪录片") || name.equals("综艺"));
|
String id = ele.attr("href");
|
||||||
if (allClass.contains(name)) show = false;
|
if (ele.attr("href").contains("category") || ele.attr("href").contains("tag")) {
|
||||||
if (show) {
|
|
||||||
allClass.add(name);
|
|
||||||
Matcher mather = regexCategory.matcher(ele.attr("href"));
|
|
||||||
if (!mather.find()) continue;
|
|
||||||
// 把分类的id和名称取出来加到列表里
|
|
||||||
String id = mather.group(1).trim();
|
|
||||||
|
|
||||||
classes.add(new Class(id, name));
|
classes.add(new Class(id, name));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -175,7 +168,7 @@ public class Ddrk extends Cloud {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
url = siteUrl + "/category/" + tid;
|
url = tid;
|
||||||
}
|
}
|
||||||
if (pg.equals("1")) {
|
if (pg.equals("1")) {
|
||||||
url = url + "/";
|
url = url + "/";
|
||||||
|
|
@ -416,9 +409,9 @@ public class Ddrk extends Cloud {
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public String playerContent(String flag, String id, List<String> vipFlags) throws Exception {
|
public String playerContent(String flag, String id, List<String> vipFlags) throws Exception {
|
||||||
if(flag.contains("quark")){
|
if (flag.contains("quark")) {
|
||||||
return super.playerContent(flag, id, vipFlags);
|
return super.playerContent(flag, id, vipFlags);
|
||||||
}else{
|
} else {
|
||||||
return Result.get().url(ProxyVideo.buildCommonProxyUrl(id, Util.webHeaders(siteUrl))).string();
|
return Result.get().url(ProxyVideo.buildCommonProxyUrl(id, Util.webHeaders(siteUrl))).string();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ public class DdrkTest {
|
||||||
|
|
||||||
@org.junit.Test
|
@org.junit.Test
|
||||||
public void categoryContent() throws Exception {
|
public void categoryContent() throws Exception {
|
||||||
String content = spider.categoryContent("drama/western-drama", "2", true, null);
|
String content = spider.categoryContent("https://ddys.mov/drama/western-drama", "2", true, null);
|
||||||
JsonObject map = Json.safeObject(content);
|
JsonObject map = Json.safeObject(content);
|
||||||
Gson gson = new GsonBuilder().setPrettyPrinting().create();
|
Gson gson = new GsonBuilder().setPrettyPrinting().create();
|
||||||
System.out.println("categoryContent--" + gson.toJson(map));
|
System.out.println("categoryContent--" + gson.toJson(map));
|
||||||
|
|
|
||||||
Binary file not shown.
|
|
@ -1 +1 @@
|
||||||
8669c4e59677fb468d72b104c792c67d
|
8c701767a5109d01ea59c6b4619c334c
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"spider": "https://androidcatvodspider.pages.dev/jar/custom_spider.jar;md5;8669c4e59677fb468d72b104c792c67d",
|
"spider": "https://androidcatvodspider.pages.dev/jar/custom_spider.jar;md5;8c701767a5109d01ea59c6b4619c334c",
|
||||||
"lives": [
|
"lives": [
|
||||||
{
|
{
|
||||||
"name": "直播ipv6",
|
"name": "直播ipv6",
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"spider": "https://androidcatvodspider.pages.dev/jar/custom_spider.jar;md5;8669c4e59677fb468d72b104c792c67d",
|
"spider": "https://androidcatvodspider.pages.dev/jar/custom_spider.jar;md5;8c701767a5109d01ea59c6b4619c334c",
|
||||||
"lives": [
|
"lives": [
|
||||||
{
|
{
|
||||||
"name": "直播ipv6",
|
"name": "直播ipv6",
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"spider": "https://androidcatvodspider.pages.dev/jar/custom_spider.jar;md5;8669c4e59677fb468d72b104c792c67d",
|
"spider": "https://androidcatvodspider.pages.dev/jar/custom_spider.jar;md5;8c701767a5109d01ea59c6b4619c334c",
|
||||||
"lives": [
|
"lives": [
|
||||||
{
|
{
|
||||||
"name": "直播ipv6",
|
"name": "直播ipv6",
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue