Skip to content

Facebook Oembed Page-Photo issue #405

@reflexxion

Description

@reflexxion

Hi,

I just found an issue in the facebook oEmbed docs (new api from 24th Oct).
In the URL Formats section they do not list "Photos in pages" but indeed this url scheme work for the "oembed_post" endpoint.

The URL format for that case should be https://www.facebook.com/{page-name}/photos/{id}
E.g. https://www.facebook.com/amrum/photos/a.10161026612345162/10161026614895162/

Using the integrated "embed post" this type of post is embeddable.

https://developers.facebook.com/docs/plugins/embedded-posts/?prefill_href=https%3A%2F%2Fwww.facebook.com%2Famrum%2Fphotos%2Fa.10161026612345162%2F10161026614895162%2F&__tn__=p*F#code-generator

I'll create a pull request for v4. v3.x is not necessary because the conditions are way different.

Section in v4:
https://github.com/oscarotero/Embed/blob/master/src/Adapters/Facebook/OEmbed.php#L57-L67
(always use page as fallback, so it does not work)

Section in v3:
https://github.com/oscarotero/Embed/blob/v3.x/src/Providers/OEmbed/Facebook.php#L55
(always use post as fallback, so it works)

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