Little stuck, i need to use Request.IsLocal inside a class library, not the web project. How should i be dong this?
System.Web and System.Web.Mvc are referenced in there.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No, I am kidding. Promise me you will never do anything like that. You shouldn’t need something like this in a class library. Or if you need it, you should pass this information to the class library as, for example, method argument from the UI layer which has the notion of Request. Otherwise you will tying your class library to ASP.NET and an HttpContext making it non-reusable.