Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#48561 closed enhancement (wontfix)

Block "Facebook Embed" inserts new fb-root every time it's included on a page

Reported by: bastianfiessinger's profile bastianfiessinger Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Embeds Keywords:
Focuses: Cc:


Every time a "Facebook" Block is included on a page, the block creates an element with the following nodes on the start:

<div id="fb-root"></div>
<script async="1" defer="1" crossorigin="anonymous" src=";version=v5.0"></script>

So there are multiple instances of id="fb-root" and the facebook sdk.js is also included multiple times if you want to display more than one Facebook post on a page.

Maybe hook in after get_header() to inlclude these nodes once as there is no ideal hook right after the body tag.

Btw: why is the sdk loaded from the french version of facebook?

Change History (3)

#1 @SergeyBiryukov
5 years ago

  • Component changed from General to Embeds

This ticket was mentioned in Slack in #core by peterwilsoncc. View the logs.

5 years ago

#3 @isabel_brison
5 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed

Thanks for reporting this! We will try to contact Facebook to get it changed on their side, so I'm closing this ticket for now.

Note: See TracTickets for help on using tickets.