Tips for improving code performance

zhaozj2021-02-16  39

Improve HTML page performance skills

Michael Wallent Microsoft

Http://msdn.microsoft.com/library/en-us/dndude/html/dude100499.asp?frame=true

A very important piece of Microsoft's development cycle is to adjust the performance of the product. Performance adjustments are also one of the key parts that developers should pay attention to. After years of development, the industry has a lot of understanding of how to optimize Win32 program performance.

One of the problems encountered by developers is not clear what caused DTHML and HTML pages to run fast or slow. Of course, there are some simple methods - such as don't use 2MB of large pictures. We have used some other interesting techniques to improve the performance of the DHTML page, I hope they can help you improve your page performance.

Here I use a program example of establishing a table. The 1000-line table (Table) is created with Document.CreateElement () and Element.Isertbefore () methods. There is a column per line. The contents included in the Cell are called "text". How can this code? How can such a small process of such a small program? Please read the introduction.

At first I wrote a self-thinking process, I tried to avoid some low-level issues --- Image like not explicitly defined, or using VBScript and JavaScript simultaneously in a page. The procedure is as follows: