24 ASP skills for improving performance and style

Source: Internet
Author: User
Tags object model
Introduction
Tip 1: cache common data on a Web server
Tip 2: cache common data in Application or Session objects
Tip 3: cache data and HTML on the Web server disk
Tip 4: avoid caching non-flexible components in the Application or Session object
Tip 5: Do not cache database connections in Application or Session objects
Tip 6: Use Session objects
Tip 7: encapsulate code in a COM object
Tip 8: Get resources later and release resources earlier
Tip 9: Off-process execution sacrifices reliability
Tip 10: use options explicitly
Tip 11: use local variables in subroutines and functions
Tip 12: copy common data to script variables
Tip 13: avoid redefining arrays
Tip 14: Use response Buffering
Tip 15: Batch processing embedded scripts and Response. Write statements
Tip 16: Use Response. IsClientConnected before starting a long task
Tip 17: use <OBJECT> to mark the OBJECT to be instantiated
Tip 18: bind the ADO object to TypeLib of other components
Tip 19: use the browser's verification capability
Tip 20: Avoid string concatenation in a loop
Tip 21: enable browser and proxy caching
Tip 22: try to replace Response. Redirect with Server. Transfer
Tip 23: add a slash to the end of the Directory URL
Tip 24: Avoid using server variables
--------------------------------------------------------------------------------
Introduction
Performance is a feature. You need to design performance in advance or re-compile the application in the future. In other words, what is a good policy to maximize the performance of Active Server Pages (ASP) applications?
This article provides many tips for optimizing ASP applications and Visual Basic (R) script editor (VBScript. Many traps and defects are discussed. The recommendations listed in this article are all tested on http://www.microsoft.com and other sites and work properly. This document assumes that you have a basic understanding of ASP development, including VBScript and/or JScript, ASP Application, ASP Session, and other ASP internal objects (requests, responses, and servers ).
The performance of ASP is usually not limited to ASP code. We do not want to include all the famous sayings in an article, but only list performance-related resources at the end. These links include ASP and non-ASP topics, including "ActiveX (R) data object (ADO)", "part Object Model (COM)", databases, and "Internet Information Server (IIS) "configuration. These are our favorite links-please pay attention to them.
Tip 1: cache common data on a Web server
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.