新增自定义ssr订阅地址

修改http→https
This commit is contained in:
2022-03-02 11:39:25 +08:00
parent 2128d7893f
commit 322e00404c
6 changed files with 268 additions and 10 deletions

View File

@@ -13,6 +13,12 @@
<div id="header"></div>
<div class="layui-body" style="left: 200px;">
<div id="side"></div>
<div class="layui-form-item">
<label class="layui-form-label">ssr订阅地址</label>
<div class="layui-input-block">
<input type="text" id="ssr" required lay-verify="required" placeholder="请输入订阅地址,回车提交" autocomplete="off" class="layui-input">
</div>
</div>
<table id="oss" lay-filter="myOssFilter"></table>
<div id="footer"></div>
</div>
@@ -73,7 +79,7 @@
} else if(obj.event === 'showUrl'){
layer.prompt({
formType: 2,
value: 'http://'+window.location.host+'/tools/clash/get.do?token=X9C2h61pDI7KFa0kaHNITjlCY7bbIFN0',
value: 'https://'+window.location.host+'/tools/clash/get.do?token=X9C2h61pDI7KFa0kaHNITjlCY7bbIFN0',
title: '请输入地址',
}, function (path, index, elem) {
$.post('/tools/clash/add.do', {'url': path}, function (json) {
@@ -87,7 +93,18 @@
})
$('#ssr').keyup(function (event) {
if(event.keyCode===13){
$.post("/tools/clash/ssr.do?url="+$('#ssr')[0].value,function (json) {
layer.msg(json.msg)
})
}
})
$.get("/tools/clash/getssr.do",function(json){
if(json.code===0){
$('#ssr')[0].value=json.data
}
})
});
$('#header').load("/html/header.html");