I want to upload a image to server side and I stored it into a specific folder. But I cant display that uploaded image in jsp page without refreshing the folder. How can I solve this problem?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You have to cause your jsp to run again and read the folder content. I do not know what framework are you using if any bu generally you should do the following. I believe that you have HTML form with
method=POSTandinputelement of typefile. Your user presses browse button, chooses file and then presses “upload” that causes the form to perform post. Then you return the view of your remote folder. You should run your jsp at the end of upload, so that user will see the JSP’s output, i.e. the new content of your folder.