ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Facebook ’Like’ button posts random code on Wall

September 20, 2011 7:59pm

Subscribe [1]
  • #1 / Sep 20, 2011 7:59pm

    maxi

    220 posts

    Hi, I’m having an issue with the Facebook Like button.

    I’m using this code, which seems to be displaying the button correctly in the page

    <div id="fb-root"></div>
    [removed](function(d, s, id) {
      var js, fjs = d.getElementsByTagName(s)[0];
      if (d.getElementById(id)) {return;}
      js = d.createElement(s); js.id = id;
      js.src = "//connect.facebook.net/it_IT/all.js#xfbml=1";
      fjs[removed].insertBefore(js, fjs);
    }(document, 'script', 'facebook-jssdk'));[removed]
    
    <div class="fb-like" data-href="http://www.website.com/" data-send="true" data-width="450" data-show-faces="false"></div>


    But the resulting Facebook wall post is a scrambled result like this:

    AC_FL_RunContent( ‘codebase’,‘http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0’,‘width’,‘572’,‘height’,‘518’,‘title’,‘websitename’,‘src’,‘slideshow’,‘quality’,‘high’,‘pluginspage’,‘http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=Shockwav…

    Any ideas why this might be happening?

    Thanks

    [Mod Edit: Moved to the Community Help forum]

  • #2 / Sep 21, 2011 11:49am

    maxi

    220 posts

    Hmmm still not working… Ever happened to you?

    What code are you using in EE 2 for the FB like button?

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases