This is what I am using. I want to be able to create remote folder structure if it doesnt exist yet.
set curlFTP to "curl --ftp-create-dirs -T " & quoted form of POSIX path of filepathtoUpload & space & quoted form of ("ftp://username:password@domain.com/htdocs/www/storage/" & remoteDirectory & "/" & realFifthPart & "-" & sixthPart & "-" & eventTime & "/")
log (curlFTP)
do shell script curlFTP
But, I keep on getting Apple Runtime Error:
“curl: (7) couldn’t connect to host”
Can anyone spot something that is obviously wrong in the above?
Okay, the problem is instead of above, you have to do this:
set curlFTP to "curl --ftp-create-dirs -T " & quoted form of POSIX path of filepathtoUpload & space & quoted form of ("ftp://username:password@ftp.domain.com/htdocs/www/storage/" & remoteDirectory & "/" & realFifthPart & "-" & sixthPart & "-" & eventTime & "/")
log (curlFTP)
do shell script curlFTP
@ftp. added after password is the difference. Works great. Well that was a quick 12 hours of eye burning enjoyment. lol