inotgo.com

Download area
File name File size
tomcat.rar 7m

Tool version compatibility problem
Tomcat It's common and free web The server .
Tomcat The origin of the name ,Tomcat It's a wild cat , Not dependent on humans , Live independently . Tomcat The author of , The original intention of this name is to hope , This server can be self reliant , provide for oneself , image Tomcat Such a wild animal is generally , Do not rely on other plug-ins , And can independently provide web The effect of service .
Correct

Step 1 : Do not use tomcat visit html   
Step 2 : use tomcat after , visit html   
Step 3 : How to start tomcat   
Step 4 : How to deploy web pages   
Step 5 : 8080 What the hell ?   

Do not use tomcat You can also open html page , But you can see it in the browser address file:d:/test.html Such a format , It is opened by opening a local file

But what we usually see on the Internet html The website is usually :
http://12306.com/index.html This form
This is because there are web The existence of the server
 Do not use tomcat visit html
Step 2 :

use tomcat after , visit html

edit top fracture
use tomcat after , You can do this 127.0.0.1:8080/test.html Like visiting a website , Visit a html The file is .

This is because tomcat Itself is a web The server ,test.html Deployed in this web On the server , So you can access it like this .
 use tomcat after , visit html
First download on the right tomcat.rar

Decompression in d: disc , Wherever you unzip , Usually decompress it in a good place to find , Because subsequent learning needs to start it frequently

Then run the batch file : D:/tomcat/bin/startup.bat

Finally, if you see Server startup in xxx ms, It indicates that the startup is successful .

notes Tomcat After startup , Don't close .... Once closed, you can't access ....

For normal operation , Please be sure to confirm the current java The environment is JDK1.8.
Enter... On the command line java -version Check
reference resources JDK Download and configuration methods : JDK1.8 And higher version download and environment variable configuration
JDK9 Not stable enough , especially Tomcat7 Can't be in JDK9 Run in , Do not use JDK9 Run this Tomcat7, Please switch to JDK8, thank you
 How to start tomcat
Deploy a fully functional web application There are many ways , But if you just deploy one test.html, It's simple

hold test.html Copy to D:\tomcat\webapps\ROOT Under the directory

You can pass http://127.0.0.1:8080/test.html Visited
 How to deploy web pages
8080 yes tomcat The default port number

The usual Internet address , For example http://12306.com/index.html There is no port number

How to make tomcat It's also made like this ? Please continue to the next chapter , to tomcat Change port


The official account of programming , Follow and get the latest tutorials and promotions in real time , thank you .


Q & A area    
2021-06-15 Follow the instructions ,404 page
North by Northwest

You need to create your own ROOT catalogue , And in ROOT Create... Under the directory WEB-INF catalogue







The answer has been submitted successfully , Auditing . Please My answer Check the answer record at , thank you
answer Or code please Fill in at least one , If you have a problem , Please ask again , Otherwise, the webmaster may not see




2020-06-10 Run a flash solution
Dream hacker

about J2EE-Tomcat-Hello Tomcat Your questions
This link has a workaround https://www.cnblogs.com/godtrue/p/4339045.html




2 One answer

up-bear
Answer time :2021-04-26
I followed this tutorial first :https://blog.csdn.net/qq_40881680/article/details/83582484 After the operation, some situations described in the link provided by the subject appear , To solve the problem . The startup page is garbled. Please see this :https://blog.csdn.net/qq_40881680/article/details/100067235 But there's a small problem with mine , After restart, use... On the command line startup.bat Command cannot open , Only by double clicking startup.bat File to open tomcat

call_me_Reven
Answer time :2020-12-14
Mine also flashed by , before JDK I did it myself , then JDK and tomcat Replace them all with how2j Website , Just



The answer has been submitted successfully , Auditing . Please My answer Check the answer record at , thank you
answer Or code please Fill in at least one , If you have a problem , Please ask again , Otherwise, the webmaster may not see




2020-06-04 website 404 It could be 8080 Port occupied , You can change the port , Or kill Take up 8080 Port process resolution .
2020-05-15 about startup.bat
2020-05-13 stay IE It can be displayed normally on the . stay chrome It's garbled


Too many questions , Page rendering is too slow , To speed up rendering , Only a few questions are displayed on this page at most . also 45 Previous questions , please Click to view

Please... Before asking questions land
The question has been submitted successfully , Auditing . Please My question Check the question record at , thank you
about J2EE-Tomcat-Hello Tomcat Your questions

Try to provide Screenshot code and Abnormal information , Help to analyze and solve problems . You can also enter this station QQ Group communication : 496725845
Ask questions and try to provide complete code , Environment description , The more conducive to the recurrence of the problem , The faster your question can be answered .
Have questions about the code in the tutorial , Please provide which step , Which line is in doubt , This makes it easy to quickly locate the problem , Improve the speed at which questions are answered
In the thousands of questions that already exist , A considerable proportion , Because of the use of and webmaster Different versions of the development environment Resulting in , For example jdk, eclpise, idea, mysql,tomcat Wait, the version of the software is inconsistent .
Please use the same version as the webmaster , You can save yourself a lot of learning time . The webmaster sorted out the software versions used in teaching , It's all here , Convenient for everyone to download : /k/helloworld/helloworld-version/1718.html

Upload screenshot