If the page is static, how does html receive parameters?
Source: Internet
Author: User
If the page is static, how does html receive parameters? If the page is static, how does html receive parameters? No clue .. How does HTML receive parameters if the page is static?
If the page is static, how does html receive parameters? No clue .. Please refer to the following link for HTML:
------ Solution --------------------
What you want to say is static and dynamic. you can use javascirpt!
------ Solution --------------------
The static address can contain parameters;
Like thred-38903-uid.html
There is a lot of information in it.
------ Solution --------------------
The performance optimization and availability should be properly balanced, rather than simply pursuing performance optimization. Otherwise, the code may deteriorate.
There is no unified static method. Generally, the URL is rewritten. For example:
Http://www.xxx.com/topic.php? Id = 390506260
Change
Http://www.xxx.com/topics/390506260
------ Solution --------------------
Yes
Http://www.xxx.com/topics/390506260.html
In this way, no parameters are required. Html pages are generated using scripts in the background. You can generate one request and access multiple requests.
Pages that contain a large amount of real-time data or are difficult to separate real-time data are difficult to be static. static pages are not recommended. This reduces the readability of the code.
------ Solution --------------------
If you want to pass the parameter, it is not really static.
There are three methods:
First:
Http://www.xxx.com/topic.php? Id = 390506260
Change
Http://www.xxx.com/topics/390506260
Second:
Http://www.xxx.com/topic.html? Id = 390506260
Converting with js is not safe
Third:
Http://www.xxx.com/topic.html? Id = 390506260
Use apache to write the rules in. htaccess.
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