Streaming live at 10am (PST)

Custom Facebook Sharing Button


#1

Hi guys,

I ve used a code from http://wb-social-sharing-concept.webflow.io/ to integrate a custom facebook sharing button to the site I m working on. Works perfect for Chrome and Safari but for Firefox the sharing pop up doesn't open.
Any advices to fix this? Thanks guys.

Unfortunatly its a bit tricky cause I cant share a read only link or something like that because our company want to keep the project as secret as possible.

Best,
Max


#2

Remove the target attribute from the facebook share link. @Waldo


#3

@samliew thanks a lot! not it works but the original window is showing that sort of message:


#4

Ugh, I just realized that snippet is incomplete.

Take this:

href="javascript:return fbshareCurrentPage();"

or this:

href="javascript:fbshareCurrentPage();void(0);"

Also, feel free to contact me for further code help and/or customization of third-party plugins


#5

@samliew Thanks! the second one works perfect!


#6

@samliew @Waldo i just realised that it shows a weird image, is there a possibility to change the image when people share the page?


#7

Great question @Edelkollektiv you actually just need to update your Open Graph image: https://help.webflow.com/article/how-to-edit-your-sites-og-title-description-and-image

Facebook also offers a handy debugging tool to scrape the new OG image when it’s ready: https://developers.facebook.com/tools/debug/