Some device names just gets "cleared" (for example device "Lees Lamp") and results in empty $v variable after parsing line 52 and 53.
-- Did not have time yet to figure out why some device names do this and some don't..
Some of my devices have spaces in the name.
Line 53 removes these and therefore device is not found anymore.
-- Why not just remove spaces before and after device name (considered typo errors). But do not remove spaces in the name itself.
Great script! Thnx for sharing.
Some device names just gets "cleared" (for example device "Lees Lamp") and results in empty $v variable after parsing line 52 and 53. -- Did not have time yet to figure out why some device names do this and some don't..
Some of my devices have spaces in the name. Line 53 removes these and therefore device is not found anymore. -- Why not just remove spaces before and after device name (considered typo errors). But do not remove spaces in the name itself.
Line 52, 53
$v = preg_replace("/^[a-zA-Z0-9]+$/", '', $v); $v = str_replace(' ', '', $v);
Workaround: For now I just commented these 2 lines and it's working.
Using Domoticz on Raspberry V3b