Alex Rivera | Logout

How to make Silverlight client aware of user's IP address

Asked 2009-09-01T12:28:21.480
10

I'm trying to figure out a way to get a Silverlight Client to be aware of the IP address of the current user. I've seen this information similarly before, but in reference to passing it back to the server, which is different from my purpose.

I'm trying to write a simple app that changes the source of the MediaElement depending on the IP address of the user. Hence, the IP address is only needed on the client side.

Is there a way to find out the IP address without using a webservice? If I must use a webservice, which one would be good to use?

Edit
Report

1 Answer

2

You cant get the ip address of the client machine using any client side mechansims (javascript,silverlight etc).

Michale Sync posted an interesting article about how to retrieve the client info from silverlight..silverlight-2-beta1-url-referrer-screen-resolution-clients-data-time-and-ip-address.

this approch should work.. But there is also limitation

It won’t be able to get the actual address if the proxy server is hiding those addresses.

answered 2009-09-01T13:00:54.030

Your Answer