The difference between .html and .aspx and how the server handles them_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:49:17
Original
1571 people have browsed it

To know .html and .aspx, you must first understand the difference between static web pages and dynamic web pages.

Static web page: There is no background database, and it does not include web pages that cannot be interacted with by the program. It is mainly used to set the style of the web page and display the content.
Dynamic web pages: As opposed to static web pages, they can interact with background data, and they need to be processed by the server and then returned to the client browser for display.
As far as html and aspx are concerned, it can be understood this way: static web pages written purely in html language have an extension of .html, while dynamic pages are dynamic instructions embedded in static html (these dynamic instructions can be Server-side scripting languages ​​such as asp and php) have an extension of .aspx

So what is the difference between how the server handles the two?

It can be seen from the above figure that if the client sends a static page request of HTML type, the server directly returns to the browser of the client for display. If it is a dynamic web page of type .aspx, the server needs to determine on the server side whether there is a server-side script language that needs to be processed on the web page. If there is no .html directly generated and returned to the client, if there is, the script will be processed and the processed script and The original html is merged into a .html file and returned to the client for display.

Note:

The browser can parse: html, css, js

Common client-side scripting languages: javascript;
Common server-side scripting languages: jsp, asp , php

Summary

Only static .html files can be interpreted on the browser, so whether the client sends a static or dynamic page request, it will eventually be returned to the client They are all static .html files.

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!