Skip to content

Uncaught TypeError #2

@agnelvishal

Description

@agnelvishal

Hello.
I am new to this repository.
I get the error.
PHP Fatal error: Uncaught TypeError: Argument 2 passed to Yoozi\Miner\Extractor::fromUrl() must be an instance of Buzz\Client\ClientInterface or null, instance of Buzz\Client\Curl given,

This is the code I use

require_once('vendor/autoload.php');
use Yoozi\Miner\Extractor;
use Buzz\Client\Curl;



$extractor = new Extractor();

// Use the Hybrid Parser.
$extractor->getConfig()->set('parser', 'meta');
// Strip all HTML tags in the description we parsed.
$extractor->getConfig()->set('strip_tags', true);

$meta = $extractor->fromUrl('https://www.skcript.com/svr/protocol-buffers-may-be-the-next-data-serialization-game-changer', new Curl)->run();
var_dump($meta);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions