Results 1 to 7 of 7

Thread: Urgent

  1. #1
    Join Date
    Mar 2011
    Posts
    21
    Rep Power
    0

    Default Urgent

    Hello Friends,

    I am in a serious trouble..Someone please help me..

    Our team is currently building a web application which contains image upload module which I am resposible for coding. Image upload comes in place where user add his profile photo.

    I just need to give the end user the option to upload a file which I already did .

    <form action="upload.jsp"
    method="post" enctype="multipart/form-data">

    Select a file:
    <input type="file" name="first" />

    <br />
    <input type="submit" name="button" value="upload" />

    </form>

    Now what I want is the coding part to upload the file to a temperory folder in server(ofcourse I need to create a folder first) and I need to store the url for the data path in database.

    I also need the coding to retrieve the url from the database and display the corresponding image to the end user like facebook do.

    Anyone please help me...

    Thanks in advance..Regards

    Naveen

  2. #2
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    11,820
    Rep Power
    19

    Default Re: Urgent

    What does your servlet currently do?
    Are you using an existing mime-multipart package (like Apaches one)?
    Will the image be stored in the database?
    If so why have a temporary folder?
    Please do not ask for code as refusal often offends.

    ** This space for rent **

  3. #3
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,361
    Blog Entries
    7
    Rep Power
    20

    Default Re: Urgent

    Quote Originally Posted by naveenpaul1987 View Post
    I am in a serious trouble..
    Why? Are you going to be keelhauled if you fail to deliver the code? Decapitated mayhap? Defenestrated? Filleted?

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

  4. #4
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,188
    Rep Power
    19

    Default Re: Urgent

    Quote Originally Posted by JosAH View Post
    Why? Are you going to be keelhauled if you fail to deliver the code? Decapitated mayhap? Defenestrated? Filleted?
    Can we watch?

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

  5. #5
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,361
    Blog Entries
    7
    Rep Power
    20

    Default Re: Urgent

    Quote Originally Posted by DarrylBurke View Post
    Can we watch?

    db
    Sure; show at eleven, popcorn and beer can be bought in the corner on your left side; don't throw anything towards the vict^H^H^H^Hparticipant and please don't touch anything while the rotating knives machine is operational; how many tickets do you want? enjoy your evening.

    kindest regards,

    Jos ;-)
    cenosillicaphobia: the fear for an empty beer glass

  6. #6
    Join Date
    Mar 2011
    Posts
    21
    Rep Power
    0

    Default Re: Urgent

    When I search on google, I found two options.

    First one is, You can store the image in database. But this seems to be a bad idea because user can upload image of any size
    to the database. Since I am using MYSQL database, it is not practical.

    Second option is upload the image to server and put the corresponding url in the database. Server will handle huge amount of data as compared to MYSQL database.

    regards

    Naveen Paul.

  7. #7
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    11,820
    Rep Power
    19

    Default Re: Urgent

    Why is saving the image in a MySQL database impractical?
    Please do not ask for code as refusal often offends.

    ** This space for rent **

Similar Threads

  1. [URGENT]SHA Encryption System...need urgent helps
    By java_idiot in forum New To Java
    Replies: 6
    Last Post: 05-02-2010, 10:04 AM
  2. Urgent
    By Anchal in forum Java Servlet
    Replies: 1
    Last Post: 04-10-2010, 05:35 PM
  3. Urgent ???
    By programmer_007 in forum Entertainment
    Replies: 0
    Last Post: 04-02-2010, 11:49 AM
  4. Help. It's urgent
    By monir6464 in forum AWT / Swing
    Replies: 2
    Last Post: 08-24-2008, 05:57 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •