• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

I have this strange display problem

 
Ranch Hand
Posts: 147
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have this problem .

In one of my JSP i am poping up a window like this.
<table>
<tr>
<td align="right">
<form action="uploademoticons.jsp" target="popup" onSubmit="window.open('','popup','width=300,height=300');">
<input type="submit" name="submit" value="Upload Emoticons">
</form>
</td>
</tr>
</table>

In the uploademoticons.jsp i am calling the emoupload.jsp

<html>
<title>Upload</title>
<body>
<br>
<br>
<% out.println("You can upload upto one MB");%>
<br>
<br>
<form action="emoupload.jsp" METHOD=POST ENCTYPE="multipart/form-data">
Upload file? <INPUT TYPE=FILE NAME=file1> <BR><br>
<INPUT TYPE=SUBMIT>
</FORM>
</body>
</html>
In the emoupload.jsp i am calling the bean which uploads icons, after that on the same popup window i want a close button and a upload another button , but those not coming up , it printing the whole html code in the window.Somehow it is not recognizing the html . is it beacuse i am doing it in reverse way , menas printing back.
Here is my emoupload.jsp
<%@ page import="java.util.*" %>
<%@ page import="com.UserBean" %>
<jsp:useBean id="upemo" scope="session" class="com.UploadEmoticons"/>
<html>
<body>
<%
upemo.uploadEmoticons(request, response);
out.println("Uploaded successfully");
%>
<table>
<tr>
<td>
<form>
<input type="submit" value="close">
</form>
</td>
</tr>
<tr>
</td>
</td>
</tr>
<tr>
<td>
<form>
<input type="submit" value="Upload Another">
</form>
</td>
</tr>
</table>
</body>
</html>
someone advice
 
Ranch Hand
Posts: 285
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Archana,
Have you tried setting the contentType explicitly using the page atribute in the JSP page?
<%@ page setContentType="text/html" %>
HTH
 
Archana Annamaneni
Ranch Hand
Posts: 147
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That was the problem , i figured it little late.Thanks anyway.
 
reply
    Bookmark Topic Watch Topic
  • New Topic