Win a copy of Succeeding with AI this week in the Artificial Intelligence and Machine Learning forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
  • Junilu Lacar
Sheriffs:
  • Tim Cooke
  • Jeanne Boyarsky
  • Knute Snortum
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:
  • salvin francis
  • fred rosenberger
  • Frits Walraven

upload file not working !!

 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have written two programs to upload files through JSP. but it is not working. please see if u could help
cliet prog:
<html>
<head>
<title>New Page 1</title>
</head>
<body>
<form method="POST" ENCTYPE="multipart/form-data" action="upload.jsp">
<p><input type="file"><input type="submit" value="upload" name="B1">
<input type="reset" value="Reset" name="B2"></p>
</form>
</body>
</html>

server prog:
<%@ page import="com.oreilly.servlet.MultipartRequest" %>
<%@ page import="java.util.*" %>
<%@ page import="java.io.File.*" %>
<html><body>
<%
MultipartRequest mreq = new MultipartRequest(request,"c:/upload/ ");
out.println("rrr");
%>
</body></head>
thanx in advance.
 
Hoo hoo hoo! Looks like we got a live one! Here, wave this tiny ad at it:
Two software engineers solve most of the world's problems in one K&R sized book
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic