[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Alternative to HttpRequest.UserHostAddress

Posted on 2011-05-10
2
Medium Priority
?
669 Views
Last Modified: 2012-06-27
To get the IP of the requestor, is there an alternative to using HttpRequest.UserHostAddress?

Sometimes I don't have a Page object handy so I need an alternative to Page.Request.UserHostAddress.
0
Comment
Question by:Tom Knowlton
2 Comments
 
LVL 21

Accepted Solution

by:
Craig Wagner earned 2000 total points
ID: 35742904
HttpContext.Current.Request
0
 
LVL 5

Author Closing Comment

by:Tom Knowlton
ID: 35757904
My eventual solution:

...
...

string path = HttpRuntime.AppDomainAppPath;

string ip = HttpContext.Current.Request.UserHostAddress;

...
...
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lots of people ask this question on how to extend the “MembershipProvider” to make use of custom authentication like using existing database or make use of some other way of authentication. Many blogs show you how to extend the membership provider c…
One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
Integration Management Part 2
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Suggested Courses

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question