Professional Documents
Culture Documents
Basic Requirements:
1. Jdk1.7.0
2. Tomcat Apache server 6.0
3. Web Browser(Any standard java compactible Browser)
Files:
1. .html file(pass1.html)
2. .java file(pass1.java)
3. web.xml(web.xml)
Steps:
1. Create the directory as(tyif) under Apache Software Foundation\Tomcat 6.0\webapps folder
of Apache Software Foundation.
2. Create .html(pass1.html) file under tyif directory.
//pass1.html
<html>
<body>
<form action="pass1">
name:<input type="text" name="t1">
password:<input type="password" name="t2">
<input type="submit" value="login">
</form>
</body>
</html>
3. Copy the WEB-INF folder from webapps\examples.
4. Paste this in tyif directory.
5. Goto WEB-INF/classes folder and create .java(pass1.java) file.
12. Start the Tomcat 6. 0 server from given directory i.e. Apache Software Foundation\Tomcat
6.0\bin.
13. Open the browser type: http://localhost:8080/tyif/pass1.html
14. Enter username & password click on login button, if the user name & password is correct then
will get the servlet response as Welcome to homepage else invalid username or password.
15. If you get 404 response code it means you have done mistake in configuring web.xml file.
Prepared By,
Jadhav Santosh B.
Lecturer Gramin Polytechnic Nanded