Facebook Like Button error

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • aberg
    Senior Member
    • Jul 2004
    • 165

    Facebook Like Button error

    The icon Like button is changed to a red error.
    I get now this message:

    The href URL must be absolute

    On internet I read this:

    It seems that Facebook changed the Like functions and in results thousands of websites are getting this kind of errors.

    But how to solved this problem in Vbulletin?
  • Loco.M
    Senior Member
    • Mar 2005
    • 4319
    • 3.5.x

    #2
    I'm sure people will ask for a link to your site to check.
    It works on this thread here, so I don't know why it wouldn't work on your site unless there is a config issue.
    -- Web Developer for hire
    ---Online Marketing Tools and Articles

    Comment

    • Philip
      Senior Member
      • Aug 2000
      • 110

      #3
      I recently started getting the same error, here is an example URL - http://forums.speedguide.net/showthr...t-as-hard-wire

      I imagine it has to do something with encoding the URL ?
      www.speedguide.net | forums.speedguide.net
      Life would be much easier if I had the source code...

      Comment

      • BirdOPrey5
        Senior Member
        • Jul 2008
        • 9613
        • 5.6.3

        #4
        EDIT- See Post #8 for better solution.


        I (and other staff) have noticed this too... I can't figure out why it works on some vBulletin and not others. My theory was Facebook hasn't changed all their servers yet.

        If (And only if) you are getting the exact error in this thread try this-

        Edit your /includes/functions_facebook.php file.

        Find the line (line 509 in 4.2.0)

        PHP Code:
                if(is_browser('ie') || is_browser('opera'))
                {
                    
        $templater->register('href'urlencode(get_fbcanonicalurl()));
                }
                else
                {
                    
        $templater->register('href'get_fbcanonicalurl());
                } 
        and change the top line from:

        PHP Code:
                if(is_browser('ie') || is_browser('opera')) 
        to:

        PHP Code:
                if(0
        Save the file and re-upload it to your server.

        Now this condition will never be true and the URL will never be encoded.

        This should prevent the error.

        NOTE- this actually isn't a problem with the Facebook App but the built in VB Facebook Like button.
        Last edited by BirdOPrey5; Mon 4 Feb '13, 3:11am.

        Comment

        • Philip
          Senior Member
          • Aug 2000
          • 110

          #5
          It was happening on our forums (but not the vB site). I removed the "urlencode" and it seems to have worked !

          I just removed all the browser conditionals and left a single line:

          Code:
          $templater->register('href', get_fbcanonicalurl());
          Thanks.
          www.speedguide.net | forums.speedguide.net
          Life would be much easier if I had the source code...

          Comment

          • aberg
            Senior Member
            • Jul 2004
            • 165

            #6
            Thanks Joe, for me that was the solution

            Comment

            • Bigmuz7
              Senior Member
              • Jul 2010
              • 143
              • 4.1.x

              #7
              Fixed me too.. thanx Joe
              www.plantandconstruction.co.uk

              Comment

              • BirdOPrey5
                Senior Member
                • Jul 2008
                • 9613
                • 5.6.3

                #8
                Actually we have an updated way to fix it now, without needing to manually edit the files at all. (Thanks to Pogo for cluing me in.)

                Instead it can be done via adding a plugin-

                To fix go to the Admin CP -> Plugins & Products -> Add New Plugin

                Product: vBulletin
                Hook: fb_like_button
                Title: Facebook Like Fix

                PHP Code:
                PHP Code:
                if ($show['fb_likebutton'] AND (is_browser('ie') || is_browser('opera')))
                {
                   
                $templater->register('href'get_fbcanonicalurl());

                Set "Active" to YES and SAVE.

                The error should go away.

                No manual file edit needed.

                If we release a fix in 4.2.1 or later you will want to delete the plugin eventually.

                Comment

                • Bombardier
                  New Member
                  • Sep 2005
                  • 11
                  • 4.2.x

                  #9
                  Hi

                  i have this plugin in installed and it works as far as connecting to facebook & posting the link however when the link to the thread is clicked the following message is displayed at my site

                  No Thread specified. If you followed a valid link, please notify the administrator

                  Comment

                  • BirdOPrey5
                    Senior Member
                    • Jul 2008
                    • 9613
                    • 5.6.3

                    #10
                    I see it is sharing with an extrs showthread.php in the URL.
                    Please open a support ticket, Attn: Joe D, and include an Admin login so I can check your setup and settings.

                    Comment

                    • BirdOPrey5
                      Senior Member
                      • Jul 2008
                      • 9613
                      • 5.6.3

                      #11
                      I got your support ticket and am working on it, but so far I know 2 things-

                      1) It doesn't happen on all threads on your forum- I did share successfully one in your Announcements forum

                      AND

                      2) It is not related to the issue or plugin in this thread because the same problem exists even when I disable the plugin

                      Comment

                      widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                      Working...