1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Lack of Interest Change to the core share_page Facebook share button

Discussion in 'Closed Suggestions' started by Chris D, May 14, 2012.

  1. Chris D

    Chris D XenForo Developer Staff Member

    This is easily fixed ourselves, but I just wonder what the logic is behind the Facebook share button in the share_page template.

    We have at least two share buttons (often more with various add-ons) which are almost identical in physical size, appearance and functionality and then there's the Facebook one which is incredibly wide, includes which of your friends have clicked it and even includes photos.

    Although this is clearly a nice feature, it does kind of look out of place compared to the others.

    It's also tricky to make additional buttons look any good when they're so far away from all of the other buttons thanks to the Facebook button being 500px wide whereas most are about 100px.

    For my most recent add on I had to do str_replace on part of the template hook just to get the button where I wanted it.

    I think, all things considered, it would just be better to have the standard button.
     
  2. Chris D

    Chris D XenForo Developer Staff Member

    I will add to this.

    Until a few months ago, I had never done any PHP coding let alone creating add-ons so I am still very much learning.

    When I wrote this, I was under the impression that the only option with regards to a template hook was to add content to the end of a template hook. Today I have found that this isn't the case.

    So actually now I will update any add-ons I have created or creating to squeeze new share buttons at the beginning of the share_page hook.

    I still think, though, that the Facebook one should be roughly the same dimensions as the others.
     
  3. x_Stricken_x

    x_Stricken_x Active Member

    It's to make it feel social, I'm assuming. In a way, users are more apt to join a site if they see "{name} and 6 of your friends recommend this." or something of the sort - unless that's just me. But I know a handful of people who think that way.
     
  4. Coop1979

    Coop1979 Well-Known Member

    It's fairly easy to change the "Recommend" button to something else, including limiting the width, choosing whether to show any friends who have recommended it, etc. Here's a stripped down version.

    Code:
    <div class="fb-like" data-send="false" data-layout="button_count" data-width="100" data-show-faces="false" data-action="recommend"></div>
     
  5. Chris D

    Chris D XenForo Developer Staff Member

    Yes I know :)

    Thanks though, that will be useful for people.
     

Share This Page