Using PhotoMover to email images:

Using PhotoMover with Applescript to send small images to other people via e-mail.

PhotoMover has an option to scale images to a selected size without changing the orginals. A file size of 800 x 600 or smaller is recommended when e-mailing images.

Email preferences in PhotoMover:

emailprefs

If your Internet Service Provider (ISP) requires authentication, select authentication. Apple's iDisk / mac.com is one example of this. The setting for apple's iTools would be: SMTP Host: smtp.mac.com, Check off Use SMTP user Authentication, and if your email was: qtfloat@mac.com, the user id would be: qtfloat.

If you drop files on PhotoMover with e-mail selected you will be prompted as follows:

emailConfirm

Please check your System Preference and confirm that the Email Address and Outgoing Mail Server is set. PhotoMover will use these settings, if you do not supply the SMTP host and/or the To address.

Using PhotoMover AppleScript to email images:

Commands: PhotoMover command definitions

email: mail image to given address
	email  reference  -- file to e-mail
		To  string  -- e-mail address to send image to 
		From  string  -- Your e-mail address (such as: user@isp.com).
		[Subject  string]  -- Subject of the e-mail
		[Content  string]  -- message text included before the image (optional).
		[smtp host  string]  -- SMTP host address (such as: mail.isp.com or smtp.isp.com).
		[smtp id  string]  -- SMTP authentication userid.  If not supplied the from user id is used.
		[smtp pw  string]  -- SMTP authentication password. required if SMTP id is supplied.
Class application: An application program
Elements:
	'cwin' by numeric index, by name, by ID, as a range of elements, satisfying a test
	'file' by name
Properties:
	properties  record  -- property that allows getting and setting of multiple properties
	name  string  [r/o]  -- the name of the application
	frontmost  boolean  [r/o]  -- Is this the frontmost application?
	version  string  [r/o]  -- the version of the application
	Thumbnails  boolean  -- Show thumbnails.
	Resize  boolean  -- resize to selected size.
	Dimension  integer  -- selected size (0 -  9).
	Debug  boolean  -- Log extra details to the log file
	Sound  boolean  -- Play a sound on completion.
	Log  boolean  -- Log information about upload to file, and not display error alerts.
	Host  integer  -- The selected host to upload to.
	
	-- Host ID's.
	-- 0 = DigiProofs
	-- 1 = ClubPhoto -- supports Picture Description and Album Selection
	-- 2 = ImageStation
	-- 3 = FotoTime  -- supports Picture Description and Album Selection
	-- 5 = Ftp
	-- 6 = mail to
	To change the host to e-mail use the following AppleScript command:
	set the Host to 6

Three Sample scripts:

Mail to user using Internet settings

- Double click this script to set the email address, subject and message content. Then optionally select images to send.

- Drop images after setting the email address to send images to the last e-mail address you sent to. Duplicate the script to create custom send to script for frequent people.

Tutorial: Create custom scripts to email to set user:

   Duplicate email with smtp auth script and rename to the name of person you wish to send pictures too.
   Double click to start the new script.
   Set the to address, use a comma (,) to separate a list of users.
   Set the Subject
   Set the Message.
   Optional send a test message or press cancel.
   
   To use Drop image on the icon, current setting will be used.
   To change settings double click on the script icon.

Sample AppleScript that prompts you to select a file and sends to predefined email address.

Note: You must edit the other email options (To, From, smtp host and add smtp pw if needed).


on run
	tell me to activate
	
	set afile to choose file with prompt "Select an image to email"

	tell application "PhotoMover"
		activate
		
		set khost to get the Host -- save the current host
		
        set the Host to 6 -- set PhotoMover to e-mail host.
		--  set timeout to some large number
		with timeout of 3600 seconds -- how long to upload? 1 hour?
			email afile 
				To "markf@kagi.com" From "markf@post.queensu.ca" 
			    Subject "a picture" smtp host "post.queensu.ca"
		end timeout
		
		set the Host to khost -- restore the selected host
	end tell
	
	tell me to activate
	beep
	display dialog "Finished emailing." with icon note buttons {"Thanx"} default button 1
	
end run
Sample AppleScript that emails to two users:
Sample script that you must edit to change all the hard code options, from, to and smtp host options. The Code:

tell application "PhotoMover"
activate -- bring PhotoMover to the front
	
    --  set timeout to some large number
    with timeout of 3600 seconds -- how long to upload? 1 hour?
    
        email {file "big:Users:Shared:Media Juster Pacakge:Backgrounds:bg Clouds.jpg"}
            To "markf@post.queensu.ca, markf@kagi.com"
            From "test@isp.com"
            Subject "a picture from Photomover"
            Content "Testing PhotoMover V2.1" & return & "Line 2"
            smtp host "smtp.mac.com"  smtp pw "xxx"
    end timeout
	
end tell
PhotoMover, the e-mail client support SMTP AUTH login

SMTP AUTH is " ..an SMTP service extension [ESMTP] whereby an SMTP client may indicate an authentication mechanism to the server, perform an authentication protocol exchange, and optionally negotiate a security layer for subsequent protocol interactions. This extension is a profile of the Simple Authentication and Security Layer [SASL]. " This is what RFC 2554 says.

For mere mortals this means that a server has a way to authenticate smtp client before we accept mail from him. If your ISP mail server may require this. Without this and with a lot of roaming customers, you end up being an open relay (because of your customers needs) and sooner or later spamers will use you and you will be banned on ORBS and other spam fighting list.

Here you can find some information about clients and servers that support SMTP auth and you will be able to secure your server and use the right client in a right way.

http://members.elysium.pl/brush/smtp-auth/index.html

Simple Mail Transfer Protocol (SMTP)
NUMERIC ORDER LIST OF REPLY CODES
that may show up in PhotoMover's log file.
         211 System status, or system help reply
         214 Help message
            [Information on how to use the receiver or the meaning of a
            particular non-standard command; this reply is useful only
            to the human user]
         220  Service ready
         221  Service closing transmission channel
         250 Requested mail action okay, completed
         251 User not local; will forward to 
          
         354 Start mail input; end with .
          
         421  Service not available, closing transmission channel
            [This may be a reply to any command if the service knows it must shut down]
         450 Requested mail action not taken: mailbox unavailable
            [E.g., mailbox busy]
         451 Requested action aborted: local error in processing
         452 Requested action not taken: insufficient system storage
          
         500 Syntax error, command unrecognized
            [This may include errors such as command line too long]
         501 Syntax error in parameters or arguments
         502 Command not implemented
         503 Bad sequence of commands
         504 Command parameter not implemented
         550 Requested action not taken: mailbox unavailable
            [E.g., mailbox not found, no access]
         551 User not local; please try 
         552 Requested mail action aborted: exceeded storage allocation
         553 Requested action not taken: mailbox name not allowed
            [E.g., mailbox syntax incorrect]
         554 Transaction failed
See: [RFC821]



Home | Using PhotoMover with iView Media Pro || Currently supported Sites || PhotoMover Quick Reference
E-Mail Support | Frequently Asked Questions