Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The difference between request.querystring, request.form and session

2025-04-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >

Share

Shulou(Shulou.com)06/01 Report--

1. Request.querystring is used to receive the question mark inside the address "?" The contents of the following parameters are not safe to read with the get method.

Request.form is used to receive the data submitted by the form, is to use the post method to read the method in the form form to see if you are get or post, usually post is used in form.

Session saves data throughout a session until the browser closes and the data disappears. Define session ["Name"] = Li Si form

2. There are five collections of request objects, which are described below:

QueryString: used to get the information in the query string attached to the url address of the client.

For example: stra=Request.QueryString ["strUserld"]

Form: used to get the information entered by the client in the FORM form. (the value of the method attribute of the form needs to be POST)

For example: stra=Request.Form ["strUserld"]

Cookies: used to obtain the Cookie information of the client.

For example: stra=Request.Cookies ["strUserld"]

ServerVariables: used to obtain the header information and server-side environment variable information in the HTTP request information issued by the client.

For example: stra=Request.ServerVariables ["REMOTE_ADDR"], return the client IP address

ClientCertificate: used to obtain authentication information of the client

For example: stra=Request.ClientCertificate ["VALIDFORM"] returns a valid start date for sites that require security authentication.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Network Security

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report