PHP large website acceleration (Static Page) (1)

Source: Internet
Author: User
What are the core technologies of large websites (bandwidth database) connection pools? 1. static pages (the core switches dynamic pages to static pages to reduce the number of database operations) 2. cache Technology (memory-based storage-memcached) 3. server Cluster (. hardware B. software Architecture) Brief Introduction

What are the core technologies of large websites (bandwidth/Database) connection pools? 1. static pages (the core switches dynamic pages to static pages to reduce the number of database operations) 2. cache Technology (memory-based storage-memcached) 3. server Cluster (. hardware B. software Architecture) Brief introduction-: 4. database optimization (. table Structure

What are the core technologies of large websites (bandwidth/Database)

Connection Pool

1. Static pages (the core switches dynamic pages to static pages to reduce the number of database operations)

2. Cache Technology (memory storage-> memcached)

3. server cluster (a. Hardware B. Software Architecture)

Brief introduction->:

4. database optimization (. table Structure (symbol 3NF) B. add an appropriate index (1.1 primary key index 1.2 General Index 1.3 unique index 1.4 full-text index sphinx) c. read/write splitting d. table sharding (vertical/horizontal ))

U page static technology

Several important concepts of u

1. Static website

Example: http: // localhost/test.html

When our page is a static page, the url we put is a static url.

Advantage: a. Use seo (search engine optimization) search engine optimization. B. Prevent SQL injection attacks

C. High efficiency due to no database operations

2. Dynamic Website

Example: http: // localhost/test. php? Age = 80

Features: Generally, user data is acceptable,

Http: // localhost/news. php? Lang = cn & class = 1 & id = 2

Dynamic Web pages do not use SEO, because the search engine believes that the content of dynamic web pages is generally related to databases, so the search engine will give up crawling.

3. pseudo-static website

Our company developed dynamic websites to be static websites for SEO and to prevent injection attacks. Such websites are called pseudo static websites.

Http: // localhost/news. php? Lang = cn & class = 1 & id = 2

Hope

Http: // localhost/news-cn-sport-id2.html (this URL is pseudo static), but please note that pseudo static website is not really static page, so, just form, access it, will still access the database

=> Pseudo-static technology

U page static classification

1. The form is divided into real static and pseudo static

2. From the perspective of scope: overall static, and local static

This section describes the AB .exe program that comes with apache. It can be used to test the efficiency of your page and test the load capacity of apache! , This program is used in the console

Syntax used:

AB .exe-n number of requests-c number of concurrent visits page url address

Indicates the number of concurrent requests sent at the same time point.

Example:

Write a test1.php page

AB .exe-n 10000-c 100 http: // localhost/test1.php

Note:

The following is a general conclusion:

① The number of online users supported by the website is roughly about 10 of the concurrent users supported

② Efficiency table for html and PHP access

What kind of Html file u will mark SEO preferences?

1. the url cannot exceed 255.

2. Do not include parameters on static pages, causing repeated crawling.

3. Try to improve meta data

4. png "alt =" James "/>

5. frame, frameset, and iframe are not recommended for pages.

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.