Topic-icon I am using easydiscuss and there is a conflict

Active Subscriptions:

None
I want to be able to share topic posts from the forum to social media. There is a conflict between the Facebook scripts so that sometimes theirs works and sometimes it doesn't because of the conflict. I was was wondering if there was some way to either:

1. resolve the conflict.

2. scrap their social buttons and add your social buttons to their topic head. I am thinking that I could add a line of code to their template. What would that line of code be in order to add the exact same buttons as found at the top of this article www.lifespringschristianchurch.org/artic...ted-up-out-of-myself ?

I am attaching the image they took of a page.
File Attachment:


Here is their post to me:
Hello William Brannan,

I'm really sorry that delayed of this reply,

It seems like Jfbconnect facebook script conflict with our Easydiscuss Facebook scripts, check my screenshot below. (when enable JFBCSystem plugin then the Facebook script will be appear on discussion page.)

If I disable this plugin - System - JFBCSystem, it should work fine now.

Can you try disable this plugin and test view on your discussion page and see that Facebook social button still missing or not.

Can you consult with jfbconnect developer regarding this and see how it goes?
The topic has been locked.
Support Specialist
11 years 3 months ago #51767 by mel
Yes, there is a conflict on your page because you are using two components with different Facebook Javascript libraries. These two libraries will not function together. EasyDiscuss uses all.js - a deprecated library that has not been recommended for use in well over a year, but still works. JFBConnect uses sdk.js - the newer and recommended library from Facebook. If you want social login/authentication with Facebook, the all.js library will not work starting April 2015, which is why we've already upgraded to the newer library. Components such as EasyDiscuss that just insert things like the like button on the page will continue to work with the older library, even after April.

1. To Resolve the Conflict: We have been suggesting to all of our users to remove the inclusion of the older library. The following code is what is being added and needs to be removed:
<!-- Facebook SDK -->
<div id='fb-root'></div>
<script type='text/javascript'>

      // Load the SDK Asynchronously
      (function(d){
      var js, id = 'facebook-jssdk'; if (d.getElementById(id)) {return;}
      js = d.createElement('script'); js.id = id; js.async = true;
      js.src = '//connect.facebook.net/en_GB/all.js';
      d.getElementsByTagName('head')[0].appendChild(js);
    }(document));

</script>
<!-- End Facebook SDK -->

2. To use JFBConnect social buttons like your example page, try inserting the following code
<div style="position: relative; top:0px; left:0px; z-index: 99;" class="scsocialbuttons standard">
{JLinkedShare layout=standard}
{SCTwitterShare layout=standard}
{SCGooglePlusOne layout=standard}
{SCPinterestShare layout=standard image=FULL_PATH_TO_IMAGE desc=Text to Pin}
{JFBCLike layout=standard share=true width=250}
</div>

If you're inserting this into a template and not each individual topic (which I'd suggest), then you should update the Pinterest easy-tag to dynamically figure out the image and description.

I hope this helps clarify the problem and help you to resolve it, but please let me know if you have any more questions.

-Melissa
The topic has been locked.
Active Subscriptions:

None
Thank you. I was able to plug it into the template.

I have no idea how to do what you suggest regarding Pinterest. I was going to use the global image for the forum since each topic will not actually have an image. The description I would like to default to the actual topic. Can you tell what I would need to change the description to, or should I ask easydiscuss?

I really appreciate your help.
The topic has been locked.
Support Specialist
11 years 3 months ago #51779 by alzander
The Pinterest button requires an explicit image and title to be included with the button. As Melissa pointed out above, you should do something like:
{SCPinterestShare layout=standard image=http://yoursite.com/link-to-image.jpg desc=Text to Pin}
That could fix the image and description. If you want the description to be dynamic, you can use some PHP code inside the EasyDiscuss template, which would look *something* like:
{SCPinterestShare layout=standard image=http://yoursite.com/link-to-image.jpg desc=<?php echo $topic->title;?>}
That PHP code is just an example. You may be able to determine the proper code from looking around the template file or you may need to contact the StackIdeas devs (who are super helpful) to get the right code that would get you the title/description code to use.

I hope that helps,
Alex
The topic has been locked.
Active Subscriptions:

None
Thanks, that took care of it. Sorry I have been so long in getting back to you. I am trying to get one more item from another company, but they are taking forever in getting back to me. I really wish we could get you guys to do what other plugins are doing so I would only have to work with you.
The topic has been locked.
Support Specialist
11 years 2 months ago #51907 by mel
Glad we were able to get you going. Let us know if you run into any other issues.

-Melissa
The topic has been locked.