Use Case:

The user uploads his video from the frontend of my website in any format he wants to Amazon S3. Now I want to covenrt that video file to MPEG-4 using Amazon Elastic Transcoder by applying AWS SDK for PHP.

What is the best practice to do that if it is possible ?

  1. Create a plugin to output the form using shortcode
  2. Submit form using Ajax call
  3. Fire off AWS-SDK calls within the form Ajax handler
  4. Poll for Elastic Transcode job status, but SNS is preferrable
  5. Push end result to Frontend User via Websocket or Email
  • Thanks. That's awesome. But just a short question: why i should use my own plugin to generate my upload form using short code, isn't it possible to use an already made form plugin (like contact form 7 or gravity forms) and their ajax calls ? – armin Nov 18 '15 at 15:07
  • You could use those form plugins as long as you are able to manipulate the end result with hooks. – Scriptonomy Nov 18 '15 at 15:20
  • you mean the end results in the 5th step? Also do you know a good place or article to start for the 5th step, since i have not used Websocket before especially for Wordpress and Amazon? – armin Nov 18 '15 at 15:35
  • Websocket is very simple. You enqueue a library such as socket.io and place your custom js code inline. – Scriptonomy Nov 18 '15 at 15:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.