Can any one tell me is there any difference between:
Request.QueryString["id"] and Request["id"]
If yes which is better to use?
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.
Request["id"]gets a value from theQueryString,Form,Cookies, orServerVariablescollections. The order in which they are searched is not specified in the documentation but when you take a look at the source code you’ll see that it is the order in which they are mentioned.So if you know where your variable resides, which you usually do, it’s better to use the more specific option.