In other words, data transmission between Asp.net pages vs ColdFusion

Source: Internet
Author: User
Tags custom name
There are several ways to transmit data between ASP. NET pages:

1. Get method:

That is to say, you can add a custom name-value set through the URL, which is usually used and convenient. In addition, you can directly access a specific page through the URL.

2. Post method:

That is, you can submit the form to pass the data in the form. You can add the hidden field to the form to customize the data.

3. Application domain variables:

Access or modify global variables on multiple pages to exchange data. Remember to lock or unlock the data during access. Because it is a variable on the server, variable types or objects with complex structures can be stored.

4. Session domain variables:

You can access or modify session variables on multiple pages to exchange data. Remember to lock or unlock the data during access. Because it is a variable on the server, variable types or objects with complex structures can be stored.

(The following method can be used for a single page or a user control)

5. viewstate domain variables:

Similar to form variables, which are stored on the customer segment page, you can use variables or objects of complex structure types (at the same time, the object must implement the serializable interface, after all, it must be serialized to the text ), but it will increase the size of the final HTML page and increase the data traffic, which can be ignored in the broadband environment.

6. Request domain variables:

Store the data to be transferred in the httpcontext structure for subsequent use by multiple requests. This is useful when applying user controls.

7. Cookie domain variables:

This is rarely used. It is generally used to save user traces.

8. cache domain variables:

Server cache variables are generally used to read data from multiple pages.

in the past, Web programming started with ColdFusion, that is, at the end of 99, CF had the following methods at that time (viewstate was not available), and there were several other methods:
sever domain : global variables on a single server
application domain : global variables on a single Program (the cluster can span multiple servers)
session domain : indicates a general session, if the cookie is not enabled on the client, you can use the uid in the URL to mark
cookie domain : similar to other web programming
request field : The get method
form field : the post method
flash domain : variables for Flash Communication
client domain : variables related to the client browser, it is mainly used for user operation tracking
custom tag field : custom local variables in the Control
CF tag field : local variables in the CF Standard Control
CGI domain : global variables for CGI access, standard variables, such as request, server, and client, are similar to the preceding methods, and CGI Environment variables are also used, generally, it is used to analyze the context of the client and server.
variable domain : variables on a single page
caller field : The called custom control to access the caller's variable. Currently, it is no longer used.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.