I have a web app that creates an employee.txt file, how do I go about printing the contents of the file from a form?
<%-- confirmation.jsp --%>
<%@ page session="false" import="java.util.*" %>
<%@page import="java.io.InputStreamReader"%>
<%@page import="java.io.BufferedReader"%>
<%@page import="java.io.DataInputStream"%>
<%@page import="java.io.FileInputStream"%>
<%--Retrieve the Employee and Hiring beans from the Request scope--%>
<jsp:useBean id="employee" scope="request" class="domain.Employee"/>
<jsp:useBean id="hiring" scope="request" class="domain.Hiring"/>
<html>
<head>
<title>New Employee Hire</title>
<link rel=alternate media=print href="Employees.txt">
</head>
<body bgcolor="Azure">
<p><b><h1>Employee Hiring: Confirmation Message</h1></b></p>
<p>Name :
<b><jsp:getProperty name="employee" property="name"/></b></p>
<p>Job Title :
<b><jsp:getProperty name="employee" property="jobTitle"/></b></p>
<p>Year :
<b><jsp:getProperty name="employee" property="yearHired" /></b></p>
<p>Gender :
<b><jsp:getProperty name="employee" property="gender" /></b></p>
<form action="index.jsp" method="post">
<input type="submit" value="More" name="more" />
***I would like to print the employee.txt file here ***
</form>
</body>
</html>