The details start running against the clock to make the website run fast

Source: Internet
Author: User
Keywords Website run

Intermediary transaction SEO diagnosis Taobao guest Cloud host technology Hall

Web site loading speed and the stability of the operation directly related to the success or failure of network marketing. On the one hand, the user's patience is limited, if the site has not been opened for more than more than 10 seconds, I am afraid nobody is willing to continue to wait; On the other hand, not only is the user is the search engine spider program, crawling Web site to obtain content resources, its waiting time is also limited. If a site is slow to open for a long time, and stability is poor, the first is that users will not often patronize, followed by the search engine will slowly give up the site. The consequences of this is that the site is indexed and ranked continuously decline, network marketing effect is getting worse. So the author has always believed that the speed of the Web site is related to network marketing, should be caused by web site operations and network Marketing personnel attach great importance to.

Impact on the speed of Web site access to a lot of factors, except similar to Web server hardware configuration, room bandwidth quality and other objective reasons, the site construction to ignore the attention to detail is the main reason for the slow speed of many web sites. For example, many Web sites now have traffic statistics analysis plug-ins, and this plug-in is not from the site itself, but more by third-party providers. For accurate statistics, the common method now is to insert the third party's statistical code (typically a JS program) into the user's website, and many statistical procedures require that this statistic program be inserted into the beginning of the site code. The site code is executed on a row-by-line basis and will stagnate if it encounters a place that cannot be loaded. This means that if there is a problem with the statistics server, the site that uses the statistics function will not open for a long time. This is just an example, the impact of the speed of the site of the subjective "negligence" factors there are many, we will be the main aspects of the following analysis:

First, the website Code concise specification

Now the vast majority of Web sites are developed with dynamic language, whether ASP or PHP, want to maintain the site late maintenance update convenience, the use of the database is necessary. First, the database read write itself is required time, the more critical factor is that if the code is not standardized, such as the lack of database shutdown statements, it will greatly affect the speed of the site load. Similar errors and the use of circular statements, resulting in a dead loop will make the site run more and more slowly. The first way to solve this type of error is to standardize the program, and second, as far as possible, the Dynamic Web page generated static HTML page, so even if the site program has problems, will not affect the user's normal access. In addition to waste code and redundant code of a large number of, HTML in the unreasonable JS and CSS fragments, will also reduce the execution efficiency of the site program, affecting the speed of access to the site.

Second, the Super large resources asynchronous loading

A page, its program code is no more than hundreds of KB, but a picture or a piece of animation video a piece of music, it may be more than a few trillion. To know that China's average bandwidth is only about 2 m, its downlink rate of about 200KB or so, a picture of 1M or so, the load will take 5 seconds to complete. And how can a website be a picture? Therefore, pictures, animations and audio and video files, but also affect the speed of Web site access is very important reason. This seems to be a very headache, but now there is a perfect solution, you seriously think about it, almost all of the portals have a large number of pictures and animation show, but why this site open so fast? The trick is to reasonably control the size of the picture and take the mode of asynchronous loading. The so-called asynchronous loading is easy to understand, that is, these large portal sites have independent picture servers, site code programs and Web site image animation, is simultaneously from different servers on the parallel transfer. In addition, the images on these sites are strictly in accordance with the display of browsing standards to compress, to control the size, which to some extent also increased the speed of loading, here limited to the space not to repeat.

Third, the reasonable configuration of the host space

To visit the site quickly, the first to improve the server's hardware configuration. The reason is very simple, like why the general computer to open a few more programs, the speed is very slow, the Web server is also a special computer. Except the hardware configuration of the Web server, the circuit of the room and the quality of the bandwidth will greatly affect the speed of the website visit. This is why we have been advising users to choose a BGP multiple-line server for mainstream access, because at least now interconnection is still a serious problem in China. Hardware configuration related to the speed of the site, software is the same, such as the server opened Gzip,gzip will be output to the user's browser data compression processing, which will reduce the amount of data transmitted over the network, improve the speed of browsing. There are now some large web operators using CDN acceleration, if the conditions are allowed and necessary, are some good choice.

Iv. Domain Name resolution straightforward

When it comes to Web site access speed, more than 90% of the people first thought must be the Web server configuration, room quality and web site procedures. In fact, the impact of Web site access speed and stability of a lot of people ignore the factors, is the domain name DNS resolution. Because the program can only recognize the IP address, but the IP address is composed of a number of digits, so the domain name resolution server needs to complete the binding work of IP. Unstable DNS resolution server, directly affects the user is the domain name after the open speed is not stable. In the domain name resolution operation, there is also a lot of details are ignored, is the domain name resolution when using a record resolution IP address, or use CNAME to resolve aliases. Shanghai Network company Pilotage Technology believes that the direct domain name resolution to IP address access speed and stability is higher than the alias resolution. Because the IP address directly corresponds to the Web server, and alias resolution to bypass the Web site host alias Resolution Server, bypass of course will affect the speed and stability of Web site access. In the domain name resolution, maybe we just save a few milliseconds, but always to improve the speed of Web Access has a positive effect.

V. Careful reference to external resources

This is to go back to the beginning of this article, Third-party plug-ins are often used to slow down the speed of Web site access is the main reason. The author has a personal experience, listen to the site traffic statistics provider's recommendations, the statistics code placed in the top of the site code, only because a small icon did not load completed, resulting in the site for a long time can not load run. Now a lot of Third-party Web site Plug-ins, its implementation of the way no more than the statistics URL links or JS program calls to achieve, so that the speed of access to the Web site and stable operation buried hidden dangers. So we have to quote traffic statistics analysis, online customer service, such as Third-party Web site Plug-ins must be cautious, and to the extent possible to put these reference code at the bottom of the site program. In this way, even if the referenced code does not load, it will not cause excessive impact on the site and interference.

If your site is running all the time and the site is slowing down, consider the possibility of being attacked. Although the network marketing has just begun, but has been disorderly elephant profusion, those in the network marketing to taste the sweetness of some enterprises also unceasingly suffers from the website to attack the distress. So in the Web site construction code and later in the process of network marketing, must not ignore the network security. Remove from code writing, server security settings, the regular inspection of the site code analysis and improve the frequency of data backup, is a good way to deal with. The importance of Web site speed not to say, improve the speed of the site to visit a lot of methods, Shanghai website Construction Company Pilotage Technology (http://www.joyweb.net.cn) that the details are the key to success, only the site construction and the details of the operation of the site to achieve the ultimate, It is possible for a Web site to run fast.

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.