I need to upload files by SFTP from a PHP script. I think cURL is probably the way, as I have this available on the server.
Has anyone got an example of how to use cURL for SFTP using identity key authentication?
-- EDIT --
I've just noticed that HTTP PUT might be an alternative, but how secure it that?