Using a simple implementation of Google's share button I'm getting the following message:
Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://accounts.google.com') does not match the recipient window's origin ('https://mydomain').
The implementation is like this one:
<!-- Place this tag in your head or just before your close body tag. -->
<script src="https://apis.google.com/js/platform.js" async defer>
{lang: 'es'}
</script>
<!-- Place this tag where you want the share button to render. -->
<div class="g-plus" data-action="share" data-height="24" data-href="https://mydomain"></div>
Some additional notes on this issue:
- This implementation is been working for years and with no changes we started to receive this console error.
- The error does not affect the correct behaviour of the Share Button.
- The error stops to be showed if, clicking the Share Button, the iFrame opens and I log into Google.
- If
<div class="g-plus" data-action="share" data-height="24" data-href="https://mydomain"></div>
is not placed on the DOM, the error stops to be shown. - This situation happens on Mac/Windows and Chrome/Firefox/Edge... Safari seems to be an exception and works properly.
Is anyone having this same issue or does anyone have more information about it?