Request. querystring ["ID"] can only read parameters named ID passed by parameters in the address bar. Request ["ID"] is a composite function for reading data. The priority order is querystring> form> cookies> servervariables. That is to say, if the address bar parameter named ID exists, the effect of request ["ID"] and request. querystring ["ID"] is similar. If the address bar parameter named ID does not exist, request. querystring ["ID"] will return NULL, but request ["ID"] will continue to check whether there is a form submission element named ID,
If it does not exist, continue to check the cookie named ID. If it does not exist, continue to check the server environment variable named ID. It will make up to four attempts, and only returns NULL if all four attempts fail. The following is the internal implementation of request ["ID "]:Code:
Public String This [ String Key]
{
Get
{
String Str = This . Querystring [Key];
If (Str ! = Null )
{
Return STR;
}
Str = This . Form [Key];
If (Str ! = Null )
{
Return STR;
}
Httpcookie = This . Cookies [Key];
If (Cookie ! = Null )
{
Return Cookie. value;
}
Str = This . Servervariables [Key];
If (Str ! = Null )
{
Return STR;
}
Return Null ;
}
}