In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly introduces how to configure the three-tier architecture of JavaWeb, which has a certain reference value. Interested friends can refer to it. I hope you will gain a lot after reading this article.
1. Software download:
1 、 java
Jdk1.4.2 is used here.
Download address: http://dlc.sun.com/jdk/j2sdk-1_4_2_07-windows-i586-p.exe;
2 、 tomcat
The version of tomcat here is 5.0. either the installation version or the unzipped version is OK.
Download address: http://apache.linuxforum.net/dis... A-tomcat-5.0.28.exe
3. Database
It is recommended to use mysql,but to find the download address for the time being. Since our class has a course design to use sqlserver, the following practice will use sqlserver (find an installation disk to install)
Note: three jar files are required to connect to sqlserver (the file name begins with ms), which can be downloaded here:
Http://www.softhouse.com.cn/html... 11250300001646.html
The complete configuration method is included above
Second, software installation:
1. Double-click to install jdk.
After installation, add the following environment variables to my computer-> Properties-> Advanced-> Environment variables-> system variables:
(suppose your JDK is installed on c:/jdk)
JDK_HOME=C:jdk
Classpath=.;%JDK_HOME%libdt.jar;%JDK_HOME%libtools.jar
Add:% JDK_HOME%bin to PATH (which already exists)
So the jdk environment is configured successfully.
two。 Double-click to install your Tomcat. (recommended installation in D:/tomcat)
Note: the tomcat5.0.x version can be used without configuring environment variables, but if you need to compile Servlet, you must also put two jar files of tomcat into the environment variables, as follows:
Add: in my computer-> Properties-> Advanced-> Environment variables-> system variables:
TOMCAT_HOME=D:tomcat
Change classpath to:.;% JDK_HOME%libdt.jar;%JDK_HOME%libtools.jar;%TOMCAT_HOME%commonlibservlet-api.jar;%TOMCAT_HOME%commonlibjsp-api.jar
This is the complete installation of Tomcat.
Suggestion: add:% JDK_HOME%bin;%TOMCAT_HOME%bin to PATH
The purpose of this is to use tomcat's tools in virtual dos
* by the way, put the three jar files downloaded in step * * into the common/lib directory under the tomcat directory.
3. Test:
Open the monitor tool of tomcat (kitten pattern) in the start menu, click start server, display the green triangle, open the browser and enter: http://localhost:8080/ in the address bar, you can see that the kitten pattern has been configured successfully.
4. Install the database (sqlserver)
Personal version or development version must be installed under windows xp (personal version is recommended).
Next can be done all the time (Microsoft's things are convenient). Notice here that you choose the local account at the domain account, and choose mixed authentication at the verification place (this is very important, if you choose system authentication, you will not be able to connect to the database in the program), enter a password for your sa users (if you practice using it, you don't have to think about security, just choose "empty password").
Third, formal programming:
1. Set up a database
Open the start menu to find the enterprise manager in the shortcut group of sqlserver. The tree on the left usually has a localhost connection. If there is a green triangle symbol, it proves that the database connection is successful. Click email to create a new database, and then create a new data table (for example, test) in your new database, and create several fields in the data table.
Add: another way to provide table creation is to use sql scripts to create tables. First, create the following file:
Test.sql
Create database test USE test create table test (id int not null identity, mark varchar, name varchar, sex varchar)
Then open the query analyzer in the sqlserver shortcut group in the start menu, click "File"-"Open", select test.sql, and click run.
Thank you for reading this article carefully. I hope the article "how to configure the three-tier structure of JavaWeb" shared by the editor will be helpful to everyone. At the same time, I also hope that you will support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.