Akito
Because Imgur image URL is using the relative protocol (//) instead of https:// or http:// and the SEO extension is getting images from content which is started with http:// or https://
public function setImageFromContent($content = null)
{
// Check post content is not empty
if($content !== null) {
// Read Post content and filter image url
$pattern = '/(?<=src=")((http.*?\.)(jpe?g|png|[tg]iff?|svg))(?=")/';
// Use image from post for social media og:image
if (preg_match_all($pattern, $content, $matches) && count($matches) > 0) {
$contentImage = $matches[0][0];
if ($contentImage !== null) {
$this->setImage($contentImage);
return $this;
}
}
}
return $this;
}
To solve this, remove preg replace
file: /vendor/fof/upload/src/Adapters/Imgur.php
// successful upload, let's get the generated URL
if ($response->getStatusCode() == 200) {
$meta = Arr::get(json_decode($response->getBody(), true), 'data', []);
$link = Arr::get($meta, 'link');
$file->url = $link; //preg_replace('/^https?:/', null, $link);
$file->remote_id = Arr::get($meta, 'id');
}
Your change will disappear after plugin update, I really don't know how to keep change using extend.php
I am a newbie here.