How to find client computer name in javascript/jsp?

后端 未结 4 1918
闹比i
闹比i 2021-01-26 08:19

My print application has to get the client name and then print the documents. How to find this in java script or jsp? I searched here. Some are discussing on PHP and so? Somethi

4条回答
  •  没有蜡笔的小新
    2021-01-26 08:35

    You can't do it with Javascript. Try building a Java applet and:

    java.net.InetAddress i = java.net.InetAddress.getLocalHost();
    System.out.println(i.getHostName());
    

提交回复
热议问题