Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to get the web application users desktop location using java

 
Ammu Isac
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

We have a web application hosted and we need to find the user's desk top location on accessing the application by the user.
I have tried System.getProperty("user.home");
and
request.getContextPath();
but these wont solve the issue as both of them provides the application serve'r location.
Please provide a solution.

Thanks.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65105
89
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you elaborate? I don't really know what you are asking for. What do you mean by "user's desktop"?
 
Bhagat Singh Rawat
Ranch Hand
Posts: 93
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ammu Isac wrote:Hi,

We have a web application hosted and we need to find the user's desk top location on accessing the application by the user.
I have tried System.getProperty("user.home");
and
request.getContextPath();
but these wont solve the issue as both of them provides the application serve'r location.
Please provide a solution.

Thanks.



If I am not wrong then you are talking about the client machine. I think you don't have access to the local file system.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You'd need to use an applet--web apps can't find out information like that about the client's machine. Imagine the security risks if they could!
 
Bhagat Singh Rawat
Ranch Hand
Posts: 93
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
David Newton wrote:You'd need to use an applet--web apps can't find out information like that about the client's machine. Imagine the security risks if they could!


I heard about Signed Applet/JavaScript but you have to pay for it!!! :D
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Pay for what?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic