PHP code example of jeremy_vk / php_video_embedder

1. Go to this page and download the library: Download jeremy_vk/php_video_embedder library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

jeremy_vk / php_video_embedder example snippets

sh
composer 

public function __construct (private VideoEmbedder $videoEmbedder){}

$videoURL = "https://www.youtube.com/watch?v=dQw4w9WgXcQ55";
$embedCode = $videoEmbedder->embedVideo($videoURL);
echo $embedCode;