PluginProbe
EmbedPress – PDF Embedder, 3D PDF FlipBook, Google Reviews, YouTube Videos, Upload & Embed PDF documents / 4.4.4
EmbedPress – PDF Embedder, 3D PDF FlipBook, Google Reviews, YouTube Videos, Upload & Embed PDF documents v4.4.4
4.6.5 4.6.4 4.6.3 4.6.2 4.6.1 4.6.0 4.5.6 4.5.5 4.5.4 4.5.3 4.5.2 trunk 1.0.0 1.1.0 1.1.1 1.1.2 1.1.3 1.2.0 1.3.0 1.3.1 1.4.0 1.4.1 1.4.2 1.4.3 1.4.4 All 189 releases
embedpress / vendor / wpdevelopers / embera / src / Embera / Provider / Vidyard.php
Vidyard.php
58 lines 1.4 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Vidyard.php
4 *
5 * @package Embera
6 * @author Michael Pratt <yo@michael-pratt.com>
7 * @link http://www.michael-pratt.com/
8 *
9 * For the full copyright and license information, please view the LICENSE
10 * file that was distributed with this source code.
11 */
12
13 namespace Embera\Provider;
14
15 use Embera\Url;
16
17 /**
18 * Vidyard Provider
19 * Vidyard is an online video platform for business which allows you to increase leads, accelerate...
20 *
21 * @link https://vidyard.com
22 * @see https://developer.vidyard.com/apidoc/oembed/show_v1_1.html
23 */
24 class Vidyard extends ProviderAdapter implements ProviderInterface
25 {
26 /** inline {@inheritdoc} */
27 protected $endpoint = 'https://api.vidyard.com/dashboard/v1.1/oembed?format=json';
28
29 /** inline {@inheritdoc} */
30 protected static $hosts = [
31 '*.vidyard.com'
32 ];
33
34 /** inline {@inheritdoc} */
35 protected $httpsSupport = true;
36
37 /** inline {@inheritdoc} */
38 protected $responsiveSupport = true;
39
40 /** inline {@inheritdoc} */
41 public function validateUrl(Url $url)
42 {
43 return (bool) (preg_match('~vidyard\.com/watch/([^/]+)~i', (string) $url));
44 }
45
46 /** inline {@inheritdoc} */
47 public function normalizeUrl(Url $url)
48 {
49 $url->convertToHttps();
50 $url->removeQueryString();
51 $url->removeLastSlash();
52
53 return $url;
54 }
55
56 /** inline {@inheritdoc} */
57 }
58