image resizing

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Shawn Northrop
    New Member
    • Jan 2007
    • 67

    #1

    image resizing

    I have created a site where users can upload images to a mysql server and then the images are displayed on another page. If possible i would like to resize the image before the data uploads. for example if the image is 1024 x 2000 and 2mb. It would resize the image to 400 x 600 and 200kb. or something of the sorts. then it would upload that data and store it in my database. As of now my script uploads, stores, and displays the image. However if it is 2mb it takes much longer to upload (and download), i am currently using (img width=400px height=600px) to display a smaller image.
  • kovik
    Recognized Expert Top Contributor
    • Jun 2007
    • 1044

    #2
    No, you cannot alter files on the user's computer.

    Comment

    • nathj
      Recognized Expert Contributor
      • May 2007
      • 937

      #3
      Perhaps, and I don't know how to do this, there is some way of restricting the size of file a user can upload to your site. In this way you would get around the problem you have and the user would have to re-size the image themselves.

      I'm sure I've seen this sort of thing somewhere, I just can't remember where.

      Cheers
      nathj

      Comment

      • jx2
        New Member
        • Feb 2007
        • 228

        #4
        you cant do that on client side but u can do it on server side before you load it to the mysql

        i wish javascript could handle pictures ;-(

        regards
        jx2

        Comment

        Working...