Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Upload Image and preview

Posted on 2006-11-20
6
10,127 Views
Last Modified: 2008-01-09
Hi

How to upload image and preview the uploaded image before inserting into the DB

Thank you
0
Comment
Question by:mmsreddy
6 Comments
 
LVL 29

Accepted Solution

by:
bloodredsun earned 32 total points
ID: 17985805
Upload it using FileUpload, get the image as an inputstream and render it as an image for preview. Or store the resulting image in the session (possibly as a RenderedImage object) and then display that.

At what point you decide to store the image is up to you.
0
 
LVL 12

Assisted Solution

by:enachemc
enachemc earned 31 total points
ID: 17985922
After you upload the image you would have to store it somewhere where it is directly accessible by the web application and serve it to the client as if it were already a part of you web app or store the image in memory (to be read session), create a servlet that when called will output this image (use output stream instead of writer) and provide the neccessary header (content type), and provide the image as having the source your servlet.
0
 
LVL 5

Assisted Solution

by:deeppra
deeppra earned 31 total points
ID: 17986105
u can do that using the javascript .. get the file path and then dynamically update the image using javascript
0
 
LVL 10

Assisted Solution

by:jaggernat
jaggernat earned 31 total points
ID: 17991883
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
netstat -a in AIX unix 8 48
struts exact match support 3 57
withoutString  challenge 40 208
equalIsNot  challenge 43 170
The advancement in technology has been a great source of betterment and empowerment for the human race, Nevertheless, this is not to say that technology doesn’t have any problems. We are bombarded with constant distractions, whether as an overload o…
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question