Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Aug 2007
    Posts
    93
    Thanks
    9
    Thanked 0 Times in 0 Posts

    Image upload - possible to compress before uploading?

    Hi there,

    I'm brand new to ASP (from PHP background) and i am developing some content management for a web site. I'm having a problem with the fact that I want to allow image files to be uploaded to a remote web server, as the hosting package the web site is on is IIS6 and has a default file upload size limit of 200kb. As it's a shared hosting package, the default limit cannot be changed for me, therefore I'm stuck with the problem of how to compress image files prior to uploading. I'm using a pure ASP file upload script which is working fine, apart from the size issue.

    Ideally, I'd like to avoid having to ask my client to resize and compress images they wish to upload to the site, therefore if anyone has any ideas that would be much appreciated.

  • #2
    Senior Coder Spudhead's Avatar
    Join Date
    Jun 2002
    Location
    London, UK
    Posts
    1,856
    Thanks
    8
    Thanked 110 Times in 109 Posts
    I can't think of anything that wouldn't involve you installing additional components on the server, which I assume your hosting package doesn't permit? If you can, then I believe you might be able to automate some image optimisation using Imagemagick.

  • #3
    Regular Coder
    Join Date
    Sep 2007
    Posts
    120
    Thanks
    0
    Thanked 3 Times in 3 Posts
    Convince your client to host his/hers website on an apache server.

    You're a php-coder, compressing images in php is a breeze, no crappy 200Kb upload limit, or missing components.

    Why was an ASP solution even considered?

    Tom

  • #4
    New to the CF scene
    Join Date
    Aug 2007
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts
    tell me about it, the php scripting with GD is really straightforward. alas the site already has a number of existing ASP files, so they want to stay on a .NET platform. i'd always use a LAMP solution whenever possible, but here I am fumbling around with ASP - having said that, it's been fine apart from the file upload issue. i suppose it's not the end of the world if i ask them to resize images before uploading....

  • #5
    Regular Coder
    Join Date
    Sep 2007
    Posts
    120
    Thanks
    0
    Thanked 3 Times in 3 Posts
    Asking the client to resize is an option, but it's just a matter of time before they forget that and you'll get a panicy e-mail about the giant wallpaper they uploaded and want resized NOW.

    Other options:
    -install a component to handle the resizing.
    - Upload to another server to handle the resizing

    HTH, Tom


  •  

    Posting Permissions

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