Fix javascript for ip range IPs