Mime-Version: |
1.0 (Apple Message framework v890.2) |
Sender: |
|
Content-Transfer-Encoding: |
7bit |
From: |
|
Date: |
Wed, 13 Jun 2007 12:37:45 -0700 |
In-Reply-To: |
|
Content-Type: |
text/plain; charset=US-ASCII; format=flowed; delsp=yes |
Reply-To: |
|
Parts/Attachments: |
|
|
global myUrl
set myUrl to "[log in to unmask]" target="_blank">ftp://user:[log in to unmask]"
sendfile(choose file)
on sendfile(AFile)
tell application "Finder" to set aname to name of AFile
if aname ends with ".txt" then
do shell script "curl -B -T \"" & POSIX path of AFile & "\" \"" &
myUrl & aname & "\""
else
do shell script "curl -T \"" & POSIX path of AFile & "\" \"" & myUrl
& aname & "\""
end if
end sendfile
On Jun 13, 2007, at 12:13 PM, Andreas Kiel wrote:
> Hi all,
>
> I'm just trying to create a shell script using "ftp" to transfer
> files from out an AppleScript. I do succeed to log in correctly to
> the remote server but I can' put files there.
> I search the web but can't find any examples of scripts which would
> work with the "do shell script"
> I found one AppleScript which uses curl, but that didn't work either.
>
> Maybe somebody got an idea.
>
> Thanks
> Andreas
>
|
|
|