SOCKS5
<%:Not Running%>
-

+
@@ -64,14 +94,14 @@ math.randomseed(os.time())
const $$ = document;
function get_state(){
- $.get('<%=url([[admin]], [[services]], [[vssr]], [[run]])%>',
+ $.get('<%=url([[admin]], [[vpn]], [[vssr]], [[run]])%>',
function (data) {
console.log(data);
}, "json");
}
//get_state();
//', null,
+ XHR.poll(5, '<%=url([[admin]], [[vpn]], [[vssr]], [[run]])%>', null,
function (x, data) {
var tb = document.getElementById('vssr_status');
var tb1 = document.getElementById('google_status');
@@ -84,6 +114,16 @@ math.randomseed(os.time())
tb.innerHTML = '<%:Client%>
<%:Running%>';
} else {
tb.innerHTML = '<%:Client%>
<%:Not Running%>';
+ }
+ if (data.google) {
+ tb1.innerHTML = '<%:Visit foreign websites%>
<%:Working...%>';
+ } else {
+ tb1.innerHTML = '<%:Visit foreign websites%>
<%:Problem detected%>';
+ }
+ if (data.baidu) {
+ tb2.innerHTML = '<%:Visit domestic website%>
<%:Working...%>';
+ } else {
+ tb2.innerHTML = '<%:Visit domestic website%>
<%:Problem detected%>';
}
if (data.game) {
tb3.innerHTML = '<%:Game Mode%>
<%:Running%>';
@@ -108,4 +148,4 @@ math.randomseed(os.time())
-
\ No newline at end of file
+