Home >Web Front-end >JS Tutorial >JS implementation method to obtain computer mac address and IP_javascript skills

JS implementation method to obtain computer mac address and IP_javascript skills

WBOY
WBOYOriginal
2016-05-16 17:05:051483browse

JS implementation method to obtain computer mac address and IP

Copy code The code is as follows:

//These two are ActiveX plug-ins in the system used to obtain ip and physical address
< ;/OBJECT>

                                                                                             abled == true)
                                                                                                            objObject.IPAddress(0) != null && objObject.IPAddress(0) != "undefined ")
IPAddr = objObject.IPAddress(0);
if(objObject.DNSHostName != null && objObject.DNSHostName != "undefined ")
sDNSName = objObject.DNSHostName;

}

🎜> var MACAddr ;
var IPAddr ;
var DomainAddr;
var sDNSName;
service.Security_.ImpersonationLevel=3;
service.InstancesOfAsync(foo, 'Win32 _NetworkAdapterConfiguration ');

                                          /SCRIPT> "



Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn