Is it possible to resize photos automatically before upload?

The Cyberduck forums have moved to Google Groups, this forum is read only.
cybermonkey
Harmless
Posts: 3
Joined: Mon Dec 29, 2008 5:14 pm

Is it possible to resize photos automatically before upload?

Postby cybermonkey » Mon Dec 29, 2008 5:21 pm

I am using Cyberduck to upload photos to my site, but I would like it to automatically resize photos before I upload. Is this possible with Cyberduck?

dkocher
Cyberduck Team
Posts: 763
Joined: Thu Feb 03, 2005 1:41 pm
Location: Switzerland
Contact:

Re: Is it possible to resize photos automatically before upload?

Postby dkocher » Sun Jan 04, 2009 4:09 pm

You can find an example in the sample script Screenshot Sample. It resizes an image using Image Events:


Code: Select all

try
   tell application "Image Events"
      launch
      -- get the image from the clipboard
      set the_image to open image_location & ".png"
      -- resize image for thumb
      scale the_image to size 133
      -- save the thumb as png
      save the_image as PNG in thumb_location & ".thumb.png"
      close the_image
   end tell
on error error_message
   display dialog error_message
end try


Return to “Cyberduck”

Who is online

Users browsing this forum: No registered users