Search…

X3 Photo Gallery Support Forums

Search…
 
User avatar
Joseph_balson
Experienced
Topic Author
Posts: 73
Joined: 08 Mar 2021, 05:35

facebook share

16 Mar 2021, 06:51

On some pages, like this one : https://www.joseph-balson.com/Blog/ the facebook share link opens the popup windows, and all is good. 

On some other pages, like this one: https://www.joseph-balson.com/Blog/ACR- ... rint-test/ it opens the popup and also opens the same FB link in the main tab/window.

happens on edge and chrome on win10 here.
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13993
Joined: 30 Sep 2006, 03:37

Re: facebook share

16 Mar 2021, 08:17

Strange! I nailed it down to one thing: Disqus comments loaded on that page, and it only happens with the Facebook link. Somehow, the scripts loaded by Disqus are interfering or hi-jacking the Facebook share link, preventing default behavior.

I will do some more research tomorrow. For now, your only "workaround" is to set "target": "_blank" for the Facebook item in Settings > Toolbar > Items. The Facebook property would then look like this:
Code
{
  "id": "facebook",
  "target": "_blank",
  "icon": "facebook",
  "label": "Share on Facebook",
  "url": "https://www.facebook.com/sharer/sharer.php?u={{url}}"
},
This will open share in a new window instead of popup, and is just a workaround (for now), if you need to avoid the issue.
 
User avatar
Joseph_balson
Experienced
Topic Author
Posts: 73
Joined: 08 Mar 2021, 05:35

Re: facebook share

16 Mar 2021, 08:26

Thanks, that will do the job.
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13993
Joined: 30 Sep 2006, 03:37

Re: facebook share

16 Mar 2021, 23:34

I looked further into this, but couldn't really find any further explanation. Essentially the toolbar Facebook link (and only Facebook) changes behavior once Disqus is loaded. This indicates that some script loaded from Disqus is specifically targeting Facebook links somehow.

I will look into a proper solution for next X3 update.