Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v4 is missing doc on Dispatcher #445

Open
Simon-L opened this issue May 8, 2021 · 0 comments
Open

v4 is missing doc on Dispatcher #445

Simon-L opened this issue May 8, 2021 · 0 comments

Comments

@Simon-L
Copy link

Simon-L commented May 8, 2021

Hello, nice tool thanks for your work!

It took me a while to realize that the conversations in the issues and elsewhere mostly refer to v3 and I could not get implementing a custom Dispatcher to work.

Taken from the v3 Readme, I've tried many variations on this:

use Embed\Embed;
use Embed\Http\CurlDispatcher;

$dispatcher = new CurlDispatcher([
    CURLOPT_MAXREDIRS => 20,
....
    CURLOPT_IPRESOLVE => CURL_IPRESOLVE_V4,
]);

$info = Embed::create('http://example.com', null, $dispatcher);

First off, CurlDispatcher has been made final and thus cannot be extended. Here: e32dc0c#diff-3afdff1b7be92454769200d4bb204c97abbdbab3e543018e7c729590e170bb95

For now I've reverted to v3.4.16 for my usecase.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant