Support » Plugin: Digg Digg » [Plugin: Digg Digg] How to set up XFBML facebook like button

Viewing 7 replies - 1 through 7 (of 7 total)
  • They use invalid code for xfbml button. To make it work with floating bar you should do next:
    1. Go to plugins->editor
    2. Select plugin to edit: Digg Digg
    3. Select file digg-digg/include/dd-class.php
    4. Find next line:

    const BASEURL = “<script src=\”\”></script><fb:like href=\”VOTE_URL\” FACEBOOK_SEND FACEBOOK_SHOW_FACE VOTE_BUTTON_DESIGN ></fb:like>”;

    5. Replace it with next code:

    const BASEURL = "<div style=\"position: relative; left: 6px;\">
    	<div id=\"fb-root\"></div>
    <script>(function(d, s, id) {
      var js, fjs = d.getElementsByTagName(s)[0];
      if (d.getElementById(id)) return;
      js = d.createElement(s); = id;
      js.src = \"//\";
      fjs.parentNode.insertBefore(js, fjs);
    }(document, 'script', 'facebook-jssdk'));</script>
    	<fb:like href=\"VOTE_URL\" FACEBOOK_SEND FACEBOOK_SHOW_FACE VOTE_BUTTON_DESIGN ></fb:like></div>";

    6. Update file
    7. Important step !!! Go to digg digg panel -> floating display. Make sure you enabled “Facebook Like (XFBML)” option and press “Save changes” button. You should do this even if you had xfbml button enabled before.
    8. Enjoy

    P.S. Tested on Digg Digg v5.2.7 in all major browsers

    Plugin Author Andrew Yates


    Thanks AlphaUA, i’ll take a look at the code and resolve the issue in the next update.

    @alphausa – what if I’m using the facebook wordpress plug in for some other facebook functions on my site? I’m assuming there is some code being duplicated. Do you suggest removing some code from the digg digg plug in and letting the facebook plug in handle adding the java?

    Hi, this code change did not work for me. Happy to help debug.

    I enabled “lazy loading” for all the other shares and now the fb FBXML is loading with code changes from above.


    what is the difference between fbxml and the others? I’m under the impression taht html5 is the way to go

    I’m not certain exactly. The FXBML version is required for using the send button. I believe FBXML is the preferred method, although I could be wrong.

    FBXML is Facebook’s XML markup and the choice to use this version for the Digg Digg plugin is independent of HTML 5.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘[Plugin: Digg Digg] How to set up XFBML facebook like button’ is closed to new replies.