D
dmckeon
I am new to Java and am trying to figure out how to run a servlet
without the need for a user to click a submit button. I have a web
service that converts a file to PDF and then a servlet that displays
the PDF file in the browser. Here is the code I have in the JSP:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<META http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<META name="GENERATOR" content="IBM Software Development Platform">
<META http-equiv="Content-Style-Type" content="text/css">
<LINK href="theme/Master.css" rel="stylesheet"
type="text/css">
<TITLE>IgRetConvTest.jsp</TITLE>
</HEAD>
<BODY>
<H1>Retrieve and Convert</H1>
<jsp:useBean id="proxy"
class="getconvert.IgRetConvProxy"></jsp:useBean>
<%
session.setAttribute("filename",
String.valueOf(proxy.retrieveConvert("<?xml version='1.0'
encoding='UTF-8'
?><IMG-PATH>C:\\\\TEST\\</IMG-PATH><IMG-NAM>TEST.IMG</IMG-NAM>")));
%>
<FORM action="/IgRetConvClient/PDFDisplay" method="post">
<INPUT type="submit" name="Submit" value="Display Image">
</FORM>
</BODY>
</HTML>
How can I run "/IgRetConvClient/PDFDisplay" without using "submit"?
without the need for a user to click a submit button. I have a web
service that converts a file to PDF and then a servlet that displays
the PDF file in the browser. Here is the code I have in the JSP:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<META http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<META name="GENERATOR" content="IBM Software Development Platform">
<META http-equiv="Content-Style-Type" content="text/css">
<LINK href="theme/Master.css" rel="stylesheet"
type="text/css">
<TITLE>IgRetConvTest.jsp</TITLE>
</HEAD>
<BODY>
<H1>Retrieve and Convert</H1>
<jsp:useBean id="proxy"
class="getconvert.IgRetConvProxy"></jsp:useBean>
<%
session.setAttribute("filename",
String.valueOf(proxy.retrieveConvert("<?xml version='1.0'
encoding='UTF-8'
?><IMG-PATH>C:\\\\TEST\\</IMG-PATH><IMG-NAM>TEST.IMG</IMG-NAM>")));
%>
<FORM action="/IgRetConvClient/PDFDisplay" method="post">
<INPUT type="submit" name="Submit" value="Display Image">
</FORM>
</BODY>
</HTML>
How can I run "/IgRetConvClient/PDFDisplay" without using "submit"?