I have an old D7 module that uses remote stream wrappers to add files on Amazon s3 to a filesystem in Drupal. There is no Remote Stream Wrapper module in Backdrop.
How do I accomplish this in Backdrop? The old call was
$file=remote_stream_wrapper_file_create_by_uri( $url );
What's the new call?
Any guidance appreciated.
Comments
Yes, that contrib module (Remote Stream Wrapper) has not been ported to Backdrop yet.
Good luck!
I don't think there's a need for a port. This functionality seems to have come into Backdrop core or is being provided by Filefield_sources. I could try s3fs, but I think the lightest weight and simplest solution is to use the remote file system capabilities already there.
See https://docs.backdropcms.org/api/backdrop/core%21modules%21file%21file.e... and the File::$uri item which notes "The URI to access the file (either local or remote)."
This implies that the capability to handle remote urls as files is already there in Backdrop core.