HP Integrity NonStop H-Series User Manual

Page 132

Advertising
background image

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ include file="/WEB-INF/jsp/include.jsp" %>
<html>
<head>
<title> Spring Getting Started - EmpInfo Application </title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
</head>
<body>
<h2 align=”center”>Welcome to the EmpInfo Application</h2>
<br>
<h2>Enter Employee Id</h2>
<form:form method="post" commandName="emprord">
<table width="95%" bgcolor="f8f8ff" border="0" cellspacing="0" cellpadding="5">
<tr>
<td align="left" width="20%">Employee Id :</td>
<td><form:input path="empid"/> </td>
</tr>
<tr>
<td align="left" width="20%">Action to Perform (Retrieve/Delete) :</td>
<td><form:input path="rord"/> </td>
</tr>
</table>
<br>
<input type="submit" align="left" value="Retrieve/Delete">
<h4><a href=<c:url value=”/”/>> Home page </a></h4>
</form:form>
</body>
</html>

3.

Create the

retrieveresult.jsp

file in the

EmpInfo/WebContent/WEB-INF/jsp

directory, as described in the

Creating the

index.jsp

File

section.

4.

Modify the

retrieveresult.jsp

file to display the details of an employee record on the

JSP page.

After modification, the

retrieveresult.jsp

file appears as:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ include file="/WEB-INF/jsp/include.jsp" %>
<html>
<head>
<title> Spring Getting Started - EmpInfo Application </title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
</head>
<body>

<table width="95%" bgcolor="f8f8ff" border="0"
cellspacing="0" cellpadding="5">
<tr>
<td align="left" width="20%">Employee Id :</td>
<td><c:out value="${model.empid}"/> </td>
</tr>
<tr>
<td align="left" width="20%">
Employee First Name : </td><td><c:out value="${model.empfn}"/> </td>
</tr>
<tr>
<td align="left" width="20%">
Employee Last Name :</td> <td><c:out value="${model.empln}"/> </td>
</tr>
<tr>
<td align="left" width="20%">
Employee Age : </td><td><c:out value="${model.empage}"/> </td>

132

Getting Started with Spring

Advertising
This manual is related to the following products: