I have an array like this
var ALLOW_SUBNET = ['192.168.1.', '192.168.2.', '192.168.3.' , '192.168.4.'];
And I can get IP address of PC Client by using my own function:
getIPClient()
var ipclient = input.getIPClient();
My question is how can I check if client IP is within my allowed subnet, I tried to use indexOf() function, but result was wrong. For example:
if IP Client is 192.168.1.115 => allow
if IP Client is 192.168.5.115 => deny.