update 2025-05-01 14:19:00
This commit is contained in:
parent
d43aee1323
commit
3d21d0fb1a
|
@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=luci-app-passwall
|
PKG_NAME:=luci-app-passwall
|
||||||
PKG_VERSION:=25.5.1
|
PKG_VERSION:=25.5.1
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
|
|
||||||
PKG_CONFIG_DEPENDS:= \
|
PKG_CONFIG_DEPENDS:= \
|
||||||
CONFIG_PACKAGE_$(PKG_NAME)_Iptables_Transparent_Proxy \
|
CONFIG_PACKAGE_$(PKG_NAME)_Iptables_Transparent_Proxy \
|
||||||
|
|
|
@ -4,9 +4,20 @@ local api = require "luci.passwall.api"
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
//<![CDATA[
|
//<![CDATA[
|
||||||
|
function getXHR() {
|
||||||
|
if (typeof XHR === 'object' && typeof XHR.create === 'function') {
|
||||||
|
return XHR.create();
|
||||||
|
} else if (typeof XHR === 'function') {
|
||||||
|
return new XHR();
|
||||||
|
} else {
|
||||||
|
throw new Error("XHR is not supported in this environment.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function ajax_add_node(link) {
|
function ajax_add_node(link) {
|
||||||
|
var xhr = getXHR();
|
||||||
if (link) {
|
if (link) {
|
||||||
XHR.post('<%=api.url("link_add_node")%>', {
|
xhr.post('<%=api.url("link_add_node")%>', {
|
||||||
'link': link
|
'link': link
|
||||||
},
|
},
|
||||||
function(x, data) {
|
function(x, data) {
|
||||||
|
|
Loading…
Reference in New Issue