WordPress.org

Ready to get started?Download WordPress

Forums

Digg Digg
Facebook button not working (29 posts)

  1. Doc75
    Member
    Posted 1 year ago #

    Hi, all of the sudden I'm getting an error on the facebook button, that worked fine until a couple days ago.
    Now I'm getting the text "Error" instead of the like button, and if I click on it I arrive on a Facebook error page that says that "The href URL must be absolute".
    Looking at my page html, I guess the error might be related to the fact thet destination url appears to be urlencoded, i.e. it's something like http%3A%2F%2Fnotizie.delmondo.info%2F2013%2F01%2F15%2F instead of http://notizie.delmondo.info/2013/01/15/
    I don't have done any upgrade or theme change in my blog in the last few days so I don't know what may have caused the error

    http://wordpress.org/extend/plugins/digg-digg/

  2. Doc75
    Member
    Posted 1 year ago #

    By the way, I forgot to mention that the problem is with the XFBML facebook button, the iframe version appears to work.

  3. danslarue
    Member
    Posted 1 year ago #

    we have the same problem, from this morning...

  4. evo252
    Member
    Posted 1 year ago #

    Lol, same pb here :)

  5. bbbarry
    Member
    Posted 1 year ago #

    Me too!

  6. dabernathy89
    Member
    Posted 1 year ago #

    Same issue here. nrcc.org

  7. kylen20
    Member
    Posted 1 year ago #

    Same problem here. Guessing FB changed something their end which is affecting it. Will switch to the iFrame version for now. Any suggestions or fixes welcome...

  8. magino
    Member
    Posted 1 year ago #

    same here.. doesn't work in post, but on homepage its fine

  9. Josh
    Member
    Posted 1 year ago #

    Having the same problem, started this morning.

  10. Flutur
    Member
    Posted 1 year ago #

    Same here.

    Any solotion yet?

  11. vanman2
    Member
    Posted 1 year ago #

    I'm having same issue. Is there an easy way to disable this plug-in until there is a fix?

  12. vanman2
    Member
    Posted 1 year ago #

    fixed it - just added the "http://www." to the "facebook.com"

  13. Flutur
    Member
    Posted 1 year ago #

    vanman2, where did you add this text?

  14. jesuscortes
    Member
    Posted 1 year ago #

    I solved it replacing the url from this:
    <?php echo urlencode(get_permalink($post->ID)); ?>
    to:
    <?php echo get_permalink(); ?>

  15. Doc75
    Member
    Posted 1 year ago #

    Ehm, are you sure you are using the Digg Digg plugin, which should be the subject of this discussion?
    I can't find any urlencode(get_permalink... text in the plugin code.

  16. ElvisKa
    Member
    Posted 1 year ago #

    Same problem here. Any solution?

  17. vanman2
    Member
    Posted 1 year ago #

    Sorry about confusion - I'm not using Digg Digg plugin but had the same issue occur because the html code on my homepage didn't have the "http://"

  18. davebos
    Member
    Posted 1 year ago #

    same here, but I am already using get_permalink() and added http:// Funny thing is that it works on one site and not on this one that are basically identical except for the app id.

    Still can't get it to work.

  19. Pinto
    Member
    Posted 1 year ago #

    I commented line 1105 on dd-class.php

    $url = rawurlencode($url);
    to
    //$url = rawurlencode($url);
  20. davebos
    Member
    Posted 1 year ago #

    And this fixed it?

    Is that easy to put into functions.php?

    Will facebook fix this instead?

  21. evo252
    Member
    Posted 1 year ago #

    OK as Pinto did, I commented all "$url = rawurlencode($url);" and it's running fine now...

  22. davebos
    Member
    Posted 1 year ago #

    Anyone know how to do that using filters in functions.php? I don't want to mess with the core code.

  23. muskie
    Member
    Posted 1 year ago #

    Needless to say I too am getting this problem and I'm hoping for an official update soon. I blogged about it as the problem isn't exclusive to Digg Digg and it seems the fix is to stop url encoding urls...

  24. muskie
    Member
    Posted 1 year ago #

    After downloading the latest version to my desktop and guided by what Pinto did above my fix to the XBFML button is to comment out the first couple lines of the constructURL function in the dd-class.php file like so:

    /*
     		if($this->isEncodeRequired){
     			$title = rawurlencode($title);
        		$url = rawurlencode($url);
     		}
     		*/

    This is working on my blog, but I think an official fix would be better... It also appears there might be some means of turning off URL encoding from inside WordPress itself, or perhaps there should be...

  25. Doc75
    Member
    Posted 1 year ago #

    @davebos
    I don't think that Facebook will "fix" this since (as far as I know) the url now does not have to be encoded in the xfbml.

    I think that the current version of the plugin did not take into account the "Like Button Migration" started a couple of months ago...

    https://developers.facebook.com/docs/reference/plugins/like/

  26. muskie
    Member
    Posted 1 year ago #

    This isn't a Facebook issue, they can totally change their API / OpenGraph format whenever they damn well please. Unfortunately they have changed it so much and made developers jump through so many hoops, it has gotten annoying. Digg Digg (Buffer) have to upgrade their plugin to be compatible with the new Facebook standard, I and others have done quick fixes and I've had to fix other PHP code.

    I have much bigger issues with the official Facebook for WordPress plugin and the instructions for installing that. Many, many, people are not starting with fresh clean installs and have blogs that are five or more years old with numerous other plugins, Facebook doesn't seem to grasp that, making bloggers register their blog as a "Facebook App" seems a bit much...

  27. davebos
    Member
    Posted 1 year ago #

    Wooops. I just realized that this was a discussion related to a plug-in, Digg Digg. Funny thing is that I am having the same issue without having that plug in installed. So I have no idea what is causing it. It occurs on one website that is almost the same as another that doesn't have the problem. I will go through and see if there are any additional plug ins. In the meantime, does anyone know how to do a full text search of all code using wordpress or cpanel? My thought is to search for string "rawurlencode" to get a clue where this is happening. I believe the standard cpanel file manager search seems to be for file names only.

  28. stratosl
    Member
    Posted 1 year ago #

    I'm using the latest wp with digg-digg and addthis-share plugins.
    What I have figured out is this:

    If I am logged on to FB in another tab, digg-digg FB button shows "error" on floating bar. If I am logged out, it shows fine.

  29. muskie
    Member
    Posted 1 year ago #

    I don't think it is that simple @statosl I've looked at the code and it is a change Facebook made to their OpenGraph API requirements. I think the Buffer boys need to upgrade the plugin or someone else does. I posted my fix above which is based on other people's fixes. It is documented on various blogs, even mine:

    Facebook sharing is busted

    This problem affected more than the Digg Digg plugin, I had to fix other PHP based Facebook sharing code with this exact issue.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic