android - How to identify a mobile device with JavaScript -


i'm developing website mobile devices. in order log behavior of users want save id cookie of user on client. when user revisits website can read id cookie identify user.

on devices works fine because device automatically accepts saving id cookie. devices (eg. iphone) doesn't work.

how can uniquely identify mobile device (eg. mac address?).

i can run javascript on mobile device.

try this, might work in case :)

    var macaddress = "";     var ipaddress = "";     var computername = "";     var wmi = getobject("winmgmts:{impersonationlevel=impersonate}");     e = new enumerator(wmi.execquery("select * win32_networkadapterconfiguration ipenabled = true"));     for(; !e.atend(); e.movenext()) {         var s = e.item();          macaddress = s.macaddress;         ipaddress = s.ipaddress(0);         computername = s.dnshostname;     }  

Comments

Popular posts from this blog

c# - SVN Error : "svnadmin: E205000: Too many arguments" -

c++ - Using OpenSSL in a multi-threaded application -

All overlapping substrings matching a java regex -