You can integrate AutoGraph-protected video easily into your Wordpress-based blog by installing the Autograph Wordpress plugin.

 

  1. Download the Autograph Wordpress plugin zip file from here: xvidmedia-autograph.zip


  2. Go to "Plugins" in your Wordpress admin backend, select "Add new" and then choose "Upload" and upload the "xvidmedia-autograph.zip" file. After the install, you should see a new plugins listed, which you may need to activate site-wide or network-wide depending on your Wordpress installation.

 

 

3. In a multi-site installation, now first choose the site you want use the plugin with. Go to "Settings" and choose "Xvid AutoGraph Settings". Then enter "https://api.xvid.com/v1/" as API Base URL and fill in the Client ID and Client Secret of one of your applications from your MediaHub account (you can obtain your client id and client secret by logging on to https://mediahub.xvid.com/app/ and go to the "Apps" tab. Click on one of your apps or create a new one, and choose "Edit" to view the corresponding Client ID and Client Secret. You may find more info about creating an App also here ).

The remaining fields in the configuration can be left empty. "Custom Error HTML" allows you to force a different error message to be rendered into your pages (and visible to the end user) in case the Autograph shortcode results in an error. But normally, the default error message is ok and the option can be left empty just like Pipeline Id and Preset Id too.

 

 

4. Once the plugin is set up, you can use short codes on any of your posts or pages to embed a Xvid AutoGraph-protected download link or video player. Note that each distributed video copy will then be automatically linked with the wordpress user id of the currently logged in user downloading the file. So you need to make sure that the Xvid AutoGraph links are embedded only into posts and pages that are non-public, meaning that they must be accessible only to logged in users.

 

The only information you need is the "file_id" of the video you want to embed. Every video (and also different version of it, e.g. different resolutions, different video qualities) created by a MediaHub conversion job has its own "file_id". You can obtain the file_ids for all your videos at https://mediahub.xvid.com/app/ under the "Info" tab when clicking the "Details" button for any of the videos listed (see the Xvid AutoGraph tutorial for more screenshots).

Examples:

Wordpress Sample Post
The below demonstrates how to embed an Xvid AutoGraph-protected download link into your post using a shortcode:

[xvid-autograph-widget file_id=562781782e206eac4246845b title="Download now!"]


And it's possible to embed a HTML5 video player that streams the video in the browser as well:

[xvid-autograph-widget file_id=562781782e206eac4246845b player=true]


You can also give more than one file_id and title description to the video player as a comma-separated list. This can be useful if you have prepared your video at different resolutions and want to allow your users to choose between them:

[xvid-autograph-widget file_id="562781782e206eac4246845b,562781782e206eac4246946c" title="1080p HD,720p HD" player=true]

 
Further, you can restrict the download link (or video player) to just users who purchased a particular Woocommerce product. 

This works by passing all "allowed" Woocommerce product ids as a comma-separated list in the "require_wc_product" parameter. If the currently logged-in user has purchased *any* of the Woocommerce products in the list, then the video is displayed/downloadable. If not, an error message is shown:
 
[xvid-autograph-widget file_id=562781782e206eac4246845b title="Woocommerce buyable video" require_wc_product="1345,6784,9885"]


Finally, and ***for testing purposes only***:

By default, the AutoGraph shortcode will generate personalized download links that contain the user id of the currently logged-in wordpress user as the "tag". And the user id is determined automatically. Because of this, the AutoGraph shortcode will work only in non-public posts and pages, where users must be logged-in first to view them.

 

But for testing purposes, you can also override the "tag" with a static string to make the shortcode work also on public pages and for non-logged in users:

 

[xvid-autograph-widget file_id=562781782e206eac4246845b title="Download now!" tag="test"]  

 

*BUT*: Make sure to use the "tag" parameter really just for testing purposes!!! If it's set, the download links are not per-user personalized anymore and so are *NOT* backtrace-able to the downloader's user id!!

 

  • No labels