Dear Friends,
I am creating a
JSP Program using bean Class to set the name, lastname & address of an emplyee.
But I am getting Confused to Put the bean folder , So please tell me the exact location of bean folder as I used in my program like bean.Employees.
<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>
<html>
<body>
<h1>Get Value from bean</h1>
<jsp:useBean id="emp" class="bean.Employees" scope="page" />
<jsp:setProperty name="emp" property="firstName" value="Komal Singh"/>
<jsp:setProperty name="emp" property="lastName" value="Choudhary"/>
<jsp:setProperty name="emp" property="adddress" value="Delhi"/>
<table>
<tr>
<td>First Name</td>
<td> : </td>
<td> <jsp:getProperty name="emp" property="firstName"/> </td>
</tr>
<tr>
<td>Last Name</td>
<td> : </td>
<td> <jsp:getProperty name="emp" property="lastName"/> </td>
</tr>
<tr>
<td>Address</td>
<td> : </td>
<td> <jsp:getProperty name="emp" property="address"/> </td>
</tr>
</table>
</body>
</html>