Google photo reference image download and upload to S3 - php

I am working on download google photo reference image and directly upload to S3 after verifying that image exists on url in PHP. Now currently I am unable to download image from google photo reference image
https://maps.googleapis.com/maps/api/place/photo?maxwidth=400&photoreference=CnRtAAAATLZNl354RwP_9UKbQ_5Psy40texXePv4oAlgP4qNEkdIrkyse7rPXYGd9D_Uj1rVsQdWT4oRz4QrYAJNpFX7rzqqMlZw2h2E2y5IKMUZ7ouD_SlcHxYq1yL4KbKUv3qtWgTK0A6QbGh87GB3sscrHRIQiG2RrmU_jF4tENr9wGS_YxoUSSDrYjWmrNfeEHSGSc3FyhNLlBU&key=XXXXXXXXX
When hit this url in web browser that browser redirect me to the another URL. Now I simply verify this url that image exists on this url or not if image exists oh this url and url is valid then simply upload this image to S3 bucket I am using Lumen microservice for this task.
If there is any third party library that provide this functionality and provide help to comlete this task. So kindly suggest.

Related

Laravel - Download specified list of images from S3 into a directory

I have been searching around but cannot find any information.
Currently have a list of images on my page and each have a download button which is just an a tag with the href of the image and the download attribute.
The client however would like to be able to download all images. Any suggestions?
Im using Vue + Laravel 5 so it can be API based etc if easier.
The aim is a download button that when clicked will allow me to specify a list of image names / urls in a bucket and then download them into a folder with a specific name.
You could consider downloading the images on the server from S3 in a temporary folder. Then you could zip that folder and provide a response to the client with the appropriate header information to start the download.

Upload Amazon S3 videos to Facebook via PHP SDK?

I'm creating an application which need to upload a video to a user profile on Facebook (web hosted application, I am using Facebook PHP SDK). Videos are hosted on Amazon S3.
I have tried to upload a video that is hosted locally on my instance, and that is working fine (authentication is OK, and the video is found to be uploaded).
But I am not able to find how to directly retrieve the video on S3 to upload it. I have read that this could be done only when the video is local. But that is not convenient for me to download the video from S3 first then upload it to Facebook.
Has anybody faced this issue, and found a way to solve it so that the video can be directly uploaded from S3 to Facebook, using the S3 Url ?
Thanks a lot for your help.

How to upload videos to youtube from url

I have an option for users to share videos. I use to filepicker.io to handle my uploads. I am using zend gdata plugin, it works well for videos stored on my server. But it does not work for videos saved on amazon s3 servers. Can I upload videos on s3 to youtube.
I appreciate any help.
The YouTube Data API requires that you send the actual bytes of the video you're uploading as part of the upload request. You can't just provide a reference to a remote URL as part of an upload request and expect the YouTube API servers to retrieve the video file from that URL.
If your video is on Amazon S3 and your code is running from a place that doesn't have direct access to the video file, then you're going to have to download it temporarily to someplace your code does have access to, and then include the video file in your YouTube upload request.

API - To upload image and to list them

I want to upload image to a image hosting service (free). I want users to upload images using the form in my website, but directly to the my image hosting's account(in a album). I don't want users to upload images to my server first and then later upload this file to imagehosting account by using my server script.
I have read about Imageshack's API and imgur API. But i donot think they will allow direct uploading.
Do you know any image hosting service or API, that allows:
uploading images directly to the image hosting account (by users of
my website, instead of using script to do the upload)
easy to use API with PHP
allows fetching of images from the albums later
Please help
Try to use uploadify library. This is very nice and usefull lib.
http://www.uploadify.com/

Dynamic policy and signature creation for browser uploads to Amazon S3

I would like to select a file in an HTML form and upload it directly to Amazon S3. I understand the principles of browser-based uploads to S3 using POST, but how can I create a policy and signature for the form if I haven't yet chosen a file to upload? Should I use AJAX to send the filename to my server and return an appropriate policy and signature based on the file extension?
You can use Ajax, Flash or any other method to upload the file to your server and then transfer it to the Amazon S3.

Categories