mirror of
https://github.com/billz/raspap-webgui.git
synced 2023-10-10 13:37:24 +02:00
Replaces absolute paths w/ relative. Enables #294
This commit is contained in:
parent
43af89cd2e
commit
1bc99e6729
@ -19,7 +19,7 @@ function createNetmaskAddr(bitCount) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function loadSummary(strInterface) {
|
function loadSummary(strInterface) {
|
||||||
$.post('/ajax/networking/get_ip_summary.php',{interface:strInterface},function(data){
|
$.post('ajax/networking/get_ip_summary.php',{interface:strInterface},function(data){
|
||||||
jsonData = JSON.parse(data);
|
jsonData = JSON.parse(data);
|
||||||
console.log(jsonData);
|
console.log(jsonData);
|
||||||
if(jsonData['return'] == 0) {
|
if(jsonData['return'] == 0) {
|
||||||
@ -31,7 +31,7 @@ function loadSummary(strInterface) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getAllInterfaces() {
|
function getAllInterfaces() {
|
||||||
$.get('/ajax/networking/get_all_interfaces.php',function(data){
|
$.get('ajax/networking/get_all_interfaces.php',function(data){
|
||||||
jsonData = JSON.parse(data);
|
jsonData = JSON.parse(data);
|
||||||
$.each(jsonData,function(ind,value){
|
$.each(jsonData,function(ind,value){
|
||||||
loadSummary(value)
|
loadSummary(value)
|
||||||
@ -50,7 +50,7 @@ function setupTabs() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function loadCurrentSettings(strInterface) {
|
function loadCurrentSettings(strInterface) {
|
||||||
$.post('/ajax/networking/get_int_config.php',{interface:strInterface},function(data){
|
$.post('ajax/networking/get_int_config.php',{interface:strInterface},function(data){
|
||||||
jsonData = JSON.parse(data);
|
jsonData = JSON.parse(data);
|
||||||
$.each(jsonData['output'],function(i,v) {
|
$.each(jsonData['output'],function(i,v) {
|
||||||
var int = v['interface'];
|
var int = v['interface'];
|
||||||
@ -91,7 +91,6 @@ function loadCurrentSettings(strInterface) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function saveNetworkSettings(int) {
|
function saveNetworkSettings(int) {
|
||||||
|
|
||||||
var frmInt = $('#frm-'+int).find(':input');
|
var frmInt = $('#frm-'+int).find(':input');
|
||||||
var arrFormData = {};
|
var arrFormData = {};
|
||||||
$.each(frmInt,function(i3,v3){
|
$.each(frmInt,function(i3,v3){
|
||||||
@ -102,8 +101,7 @@ function saveNetworkSettings(int) {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
arrFormData['interface'] = int;
|
arrFormData['interface'] = int;
|
||||||
$.post('/ajax/networking/save_int_config.php',arrFormData,function(data){
|
$.post('ajax/networking/save_int_config.php',arrFormData,function(data){
|
||||||
//console.log(data);
|
|
||||||
var jsonData = JSON.parse(data);
|
var jsonData = JSON.parse(data);
|
||||||
$('#msgNetworking').html(msgShow(jsonData['return'],jsonData['output']));
|
$('#msgNetworking').html(msgShow(jsonData['return'],jsonData['output']));
|
||||||
});
|
});
|
||||||
@ -113,7 +111,7 @@ function applyNetworkSettings() {
|
|||||||
var int = $(this).data('int');
|
var int = $(this).data('int');
|
||||||
arrFormData = {};
|
arrFormData = {};
|
||||||
arrFormData['generate'] = '';
|
arrFormData['generate'] = '';
|
||||||
$.post('/ajax/networking/gen_int_config.php',arrFormData,function(data){
|
$.post('ajax/networking/gen_int_config.php',arrFormData,function(data){
|
||||||
console.log(data);
|
console.log(data);
|
||||||
var jsonData = JSON.parse(data);
|
var jsonData = JSON.parse(data);
|
||||||
$('#msgNetworking').html(msgShow(jsonData['return'],jsonData['output']));
|
$('#msgNetworking').html(msgShow(jsonData['return'],jsonData['output']));
|
||||||
@ -186,7 +184,7 @@ function loadWifiStations(refresh) {
|
|||||||
$('.js-wifi-stations')
|
$('.js-wifi-stations')
|
||||||
.addClass('loading-spinner')
|
.addClass('loading-spinner')
|
||||||
.empty()
|
.empty()
|
||||||
.load('/ajax/networking/wifi_stations.php'+qs, complete);
|
.load('ajax/networking/wifi_stations.php'+qs, complete);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -234,7 +232,6 @@ $(function() {
|
|||||||
|
|
||||||
function set_theme(theme) {
|
function set_theme(theme) {
|
||||||
$('link[title="main"]').attr('href', 'app/css/' + theme);
|
$('link[title="main"]').attr('href', 'app/css/' + theme);
|
||||||
|
|
||||||
// persist selected theme in cookie
|
// persist selected theme in cookie
|
||||||
setCookie('theme',theme,90);
|
setCookie('theme',theme,90);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user