PHP code example of maalls / og-tag-scraper

1. Go to this page and download the library: Download maalls/og-tag-scraper 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/ */

    

maalls / og-tag-scraper example snippets

 
use Maalls\OGTagScraper\OGTagScraper;

$scraper = new OGTagScraper;
$tags = $scraper->scrap("http://someurl.com");
var_dump($tags);
command
./vendor/bin/phpunit --bootstrap vendor/autoload.php tests/