mirror of
https://github.com/jokob-sk/NetAlertX.git
synced 2025-12-07 09:36:05 -08:00
encode special characters when saving device details #644🚑
This commit is contained in:
@@ -1443,15 +1443,15 @@ function setDeviceData (direction='', refreshCallback='') {
|
||||
|
||||
// update data to server
|
||||
$.get('php/server/devices.php?action=setDeviceData&mac='+ mac
|
||||
+ '&name=' + $('#txtName').val()
|
||||
+ '&owner=' + $('#txtOwner').val()
|
||||
+ '&name=' + encodeURIComponent($('#txtName').val())
|
||||
+ '&owner=' + encodeURIComponent($('#txtOwner').val())
|
||||
+ '&type=' + $('#txtDeviceType').val()
|
||||
+ '&vendor=' + $('#txtVendor').val()
|
||||
+ '&vendor=' + encodeURIComponent($('#txtVendor').val())
|
||||
+ '&icon=' + encodeURIComponent($('#txtIcon').val())
|
||||
+ '&favorite=' + ($('#chkFavorite')[0].checked * 1)
|
||||
+ '&group=' + $('#txtGroup').val()
|
||||
+ '&location=' + $('#txtLocation').val()
|
||||
+ '&comments=' + $('#txtComments').val()
|
||||
+ '&group=' + encodeURIComponent($('#txtGroup').val())
|
||||
+ '&location=' + encodeURIComponent($('#txtLocation').val())
|
||||
+ '&comments=' + encodeURIComponent($('#txtComments').val())
|
||||
+ '&networknode=' + $('#txtNetworkNodeMac').attr('data-mynodemac')
|
||||
+ '&networknodeport=' + $('#txtNetworkPort').val()
|
||||
+ '&staticIP=' + ($('#chkStaticIP')[0].checked * 1)
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
### Notes
|
||||
|
||||
The first run will take a while, subsequent should be much faster because new sensors don't have to be created anymore. A bit of background:
|
||||
The first run will take a while, subsequent should be much faster because new sensors don't have to be created anymore. If the first sync times out, try to increase the timeout setting (default: 10s per device). A bit of background:
|
||||
|
||||
1. The app keeps a hash of the sensors. The hash includes:
|
||||
- deviceId: Unique identifier for the device associated with the sensor.
|
||||
|
||||
@@ -332,7 +332,7 @@
|
||||
{
|
||||
"function": "RUN_TIMEOUT",
|
||||
"type": "integer",
|
||||
"default_value": 10,
|
||||
"default_value": 20,
|
||||
"options": [],
|
||||
"localized": ["name", "description"],
|
||||
"name" : [{
|
||||
|
||||
Reference in New Issue
Block a user