I am looking for some help / guidance to do a pretty specific thing.
I have looked extensively and found some people online asking the same question but with no answers.
There is a WordPress tool available that makes it pretty easy to display a screenshot of a URL using the following:
hidden link + [ URL-encoded URL ] + ?w=###
(example: hidden link)
And while you can use this to display the screenshot, I want to go a step further and save this image locally after it is generated. Here is the situation:
I have a custom post type 'Video' that contains a field 'URL'
What I would like to happen is the following:
1. User publishes a ‘Video’ containing a URL (using a CRED form)
2. Screenshot of that URL is generated
2a) the tool I mentioned above takes a couple minutes to generate the image. While it is being
generated the dynamic mshot url displays a default loading GIF. For that reason, the function somehow has to know when the screenshot is ready.
3. Said screenshot is saved locally
4. Local screenshot is used as featured image for the post
Any information on how I should go about doing this would be helpful.
Please let me know if anything is unclear or more information is needed.
Thanks.
I don't know the code, or how that Service you use, works.
Clear is, this is not within Toolset features or support.
You can let users submit and URL of course, using CRED.
I assume you know how to do that, otherwise please let me know, I can point to DOC's and give instructions.
Then, if you generate an image from that URL later on, it is fully up to that service to determine where, when and how data is stored.
I suspect that data is never stored on your Server but comes from an Online Service.
As such it would somehow need a communication between that service and your Installation, and that is not done by Toolset, as such, we cannot assist a custom code that interacts with their API if they have one.
With Toolset, I would recommend using a ScreenShot that a user uploads in the Form.