How did u guys add like button

Discussion in 'Site & Server Administration' started by msk19994, Jun 21, 2010.

  1. #1
    Sir
    I wanted to ask u how did u add like button to your site because when i enter the iframe in the site only the front page is liked when i am in the other page of the site the thing is that there is another code XFBML
    i dont how how to connect it to a javascript ie i have added the code of XFBML but i dont know how to connect it to the javascript code ie

    <div id="fb-root"></div>
    <script>
    window.fbAsyncInit = function() {
    FB.init({appId: 'your app id', status: true, cookie: true,
    xfbml: true});
    };
    (function() {
    var e = document.createElement('script'); e.async = true;
    e.src = document.location.protocol +
    '//connect.facebook.net/en_US/all.js';
    document.getElementById('fb-root').appendChild(e);
    }());
    </script>

    so pls tell me what to do i hav already created a file called connect.js i dont know how to connect it
     
    msk19994, Jun 21, 2010 IP
  2. digitalpoint

    digitalpoint Overlord of no one Staff

    Messages:
    38,334
    Likes Received:
    2,613
    Best Answers:
    462
    Trophy Points:
    710
    Digital Goods:
    29
    #2
    There is a Like button option built into vBulletin 4.0.4... easiest option is to just use that.
     
    digitalpoint, Jun 21, 2010 IP
  3. msk19994

    msk19994 Well-Known Member

    Messages:
    1,030
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    160
    #3
    sir i dont have a forum i have a video sharing site i want like when a person is in a show like chuck and i click like the link which is posted should be the chuck programs url not the website main url
     
    msk19994, Jun 21, 2010 IP
  4. lowridertj

    lowridertj Well-Known Member

    Messages:
    2,882
    Likes Received:
    40
    Best Answers:
    0
    Trophy Points:
    195
    #4

    easiest way would be to use the iframe version on your site.
    it will pull the name, description, thumb image from your header.

    
    <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2FYOUR=DOMAIN=HERE.COM&amp;layout=button_count&amp;show_faces=false&amp;width=450&amp;action=like&amp;font=verdana&amp;colorscheme=light&amp;height=35" style="border: medium none; overflow: hidden; width: 450px; height: 35px;" allowtransparency="true" frameborder="0" scrolling="no"></iframe>
    
    HTML:
    use this information in the header of your page
    
    <meta property="og:title" content="TITLE-OF-PAGE"/>
    <meta property="og:url" content="YOUR-SITE-URL"/>
    <meta property="og:image" content="LINK-TO-IMAGE-ON-YOUR-SITE-50x50"/>
    <meta property="og:description" content="DESCRIPTION-OF-CONTENT"/>
    <meta property="og:site_name" content="SITE-NAME"/>
    
    HTML:

    Details more on facebook at: http://developers.facebook.com/docs/reference/plugins/like
    will generate your iframe code for you.

    Hope this helps.
     
    lowridertj, Jun 30, 2010 IP
  5. msk19994

    msk19994 Well-Known Member

    Messages:
    1,030
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    160
    #5
    thanks mate for the reply but my problem is solved via wibgya toolbar
     
    msk19994, Jun 30, 2010 IP