? HTML (hypertext Markup Language) Text Markup Language, it is a static page , and JavaScript as the explanatory language, why is it interpreted language? Because, as long as you have a browser then it can be displayed normally, without the need for the specified compilation tool, just write the HTML tag in the TXT document OK.
JSP (Java Server page) to see this meaning is the Java service side of the page, so it is dynamic , it needs to be compiled after the JDK to send the content to the client to display, we all know that the Java file compiled will produce a class file, The final implementation is the class file, JSP is the same, it will be compiled into a class file! JSP not only to compile, it has to be translated, first the JSP translated into a servlet file, and then compiled into a class file. When the user accesses the JSP, it executes the class file and finally ...
1. The simplest difference is that HTML can be opened directly, JSP can only be published to Tomact and other servers to open
2. The definition on the HTML page is a static page can be run directly, JSP page is a dynamic page it needs to be converted into a servlet when running
3. Their header is different, this is the head of the JSP "<%@ page language=" java "import=" java.util.* "pageencoding=" GBK "%>" in the header there are encoding format and import package, etc.
4. It is also very good to distinguish between the use of <%%> in the JSP can write Java code, and HTML does not have <%%>
Advantages of HTML: Advantages of JSP:
1. The front end and back end of the development process, interactive through the JSON transmission to achieve &N bsp; 1. can be crawled to 2. More cross-platform capabilities, supported by browsers , &NB Sp &NBS P 2. Reduce the number of requests 3. Enable backend data interface to be reused , &NB Sp , &NB Sp 3. Regardless of browser compatibility html Disadvantages: &NBSP ; , &NB Sp , &NB Sp JSP disadvantages: 1. Difficult to develop, consider browser compatibility , &N Bsp , &NB Sp 1. Increased server pressure 2. Page request too much , &NB Sp , &NB Sp 2. Front End and Back end not disengaged, slow development progress 3. Belong to post-load, cannot be crawled to &NB Sp , &NB Sp 3 . Too dependent on Java operation Environment 4. Interface code needs a lot of new &N Bsp , &NB Sp , &NB Sp 4. Reuse is low. 5. Cannot display Java entity class object directly, need to convert to JSON format
Differences between HTML and JSPs and their pros and cons