它是基于Java语言的一种软件设计体系结构,它是一种标准中间件体系结构。它的作用在于能标准化企业级多层结构应用系统的部署,并且简化开发环境。
eclipse-jee-2018-12-R-win32-x86_64
apache-tomcat-9.0.37-windows-x64
JDK
参考
Java-day01(基本常识,环境搭建,注释,HelloWorld)
注:一定要记住JDK安装存在的位置
apache-tomcat
直接用解压软件解压压缩包即可
eclipse
eclipse.exe
右键发送到桌面快捷方式,方便以后的使用eclipse
的快捷方式打开eclipse
Window --> General --> Appearance --> Colors and Fonts --> Basic --> Text Font
根据实际情况选择合适大小
编码方式:
Window --> Web ---> JSP Files ---> Encoding选择UTF-8(第一个) --> Apply
HTML5:
Window --> Web ---> JSP Files ---> Editor --> Templates --> 选择html 5 ---> Editor -->参照下图 --> OK ---> Apply --> Apply and Close
apache-tomcat
Server --> 点击出现的链接,进行配置
选择apache-tomcat9.0
,点击next
选择apache-tomcat
的文件,点击Finish
test Server
在dos下,输入 netstat -ano|findstr 8080
//说明:查看占用8080端口的进程
显示占用端口的进程
taskkill /pid 6856 /f
//说明,运行windows自带taskkill命令,将上面显示的进程号,结束掉。
file --> new --> Dynamic Web Project --> 填写项目名 --> Finish --> Java Resources --> src --> new --> class --> 填写类名,并勾选public static void main(String[] args) --> Finish
编写代码
Build Path
右键项目名称->Build Path->Configure Build Path ---> Add Library,选择添加`apache-tomcat`版本 ---> Finish
注:也可以在创建项目之前,完成配置。在Window -->搜索Build Path即可
点击WebContent,右键选择New ---> 选择JSP File ---> 编写文件名 ---> Finish
编写代码
感谢大家的支持,关注,评论,点赞!