| | |
Transfering Data from java to server using jsp
Please support our JSP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Sep 2008
Posts: 1
Reputation:
Solved Threads: 0
Hi all,
I'm very new in this area and I'm looking for some help. What I eventually want to do is upload a file from my java application to a server, for the moment I've installed Apache on my local machine for development/testing. The way I see this working (please correct me if I'm wrong) is that the java side tries to POST to the JSP file in the server. So the URL would be something like http://localhost:8080/test/test_upload.jsp
In the test_upload.jsp file there is code that readily reads in the data that has been sent, this could for example be a String or a File.
I'm trying to get a really simple example working first. So just passing a String that gets sent to the server and printed out in the log.
What I'm looking for is the code for both sides of this (java file and JSP file). A simple example of this on a page on the web would be prefect. I've looked everywhere but keep encountering applets and servlets or form data being sent from HTML. Might be that I've been looking for the wrong thing.
Thanks for your help,
Gaff
I'm very new in this area and I'm looking for some help. What I eventually want to do is upload a file from my java application to a server, for the moment I've installed Apache on my local machine for development/testing. The way I see this working (please correct me if I'm wrong) is that the java side tries to POST to the JSP file in the server. So the URL would be something like http://localhost:8080/test/test_upload.jsp
In the test_upload.jsp file there is code that readily reads in the data that has been sent, this could for example be a String or a File.
I'm trying to get a really simple example working first. So just passing a String that gets sent to the server and printed out in the log.
What I'm looking for is the code for both sides of this (java file and JSP file). A simple example of this on a page on the web would be prefect. I've looked everywhere but keep encountering applets and servlets or form data being sent from HTML. Might be that I've been looking for the wrong thing.
Thanks for your help,
Gaff
•
•
•
•
I've looked everywhere but keep encountering applets and servlets
The code in the applets is the client side code, all you have to do is study the networking code in the Applet and implement it in your client application.
And as far as your server side code in JSPs goes ..... I think you should know that JSPs are basically extensions of servlets.
"Any fool can write code that a computer can understand. Good programmers write code that humans can understand."
"How to ask questions the smart way ?"
"How to ask questions the smart way ?"
![]() |
Other Threads in the JSP Forum
- Previous Thread: free jsp web hosting
- Next Thread: Authentication Problem
| Thread Tools | Search this Thread |
apache backbutton combobox connection database development directorystructure dynamicpagetitles eclipse frames glassfish ie8 imagetodatabse imageupload integer internet java javaee javascript jsf jsp jsppagetitles levels mvc2 mvcmodel2 network parameters passing ping printinserverinsteadofclient redirect request.getparameter response servlet servletdopost()readxml sessions software ssl state_saving_method stocks sun tomcat tutorial update video web






