Any idea how this is done?

Hi All.

Just seen a great way of sharing comments linked to facebook using a competition as an incentive.

Brilliant idea for gaining exposure.

Has anyone got any idea how this can be done?

See http://www.maplin.co.uk/christmas-competition-2011

-Nick

  • DavidM
    • DEV MAN’s Mascot

    Hi Nick,

    Not sure exactly how it’s done but I imagine they’re just displaying the Facebook comments in order of number of Likes from Highest to Least.

    It really is a great idea I think. I wonder if it might be possible to have comments ordered that way in Comments Plus and/or Ultimate Facebook. I’m gonna mention this to some of the guys over here.

    -David

  • harryhayes
    • The Incredible Code Injector

    Hi.

    Sussed this out and it is really simple with the following code. I put this straight into a page…NB you need a facebook app id (insert where shown. Also replace localsave.co.uk with your site url. Work like a charm.


    <div id=”fb-root”></div>

    <script>

    window.fbAsyncInit = function() {

    FB.init({

    appId : ‘APP ID HERE’, // App ID

    channelUrl : ‘//www.localsave.co.uk/channel.html’, // Channel File

    status : true, // check login status

    cookie : true, // enable cookies to allow the server to access the session

    oauth : true, // enable OAuth 2.0

    xfbml : true // parse XFBML

    });

    // Additional initialization code here

    };

    // Load the SDK Asynchronously

    (function(d){

    var js, id = ‘facebook-jssdk’; if (d.getElementById(id)) {return;}

    js = d.createElement(‘script’:wink:; js.id = id; js.async = true;

    js.src = “//connect.facebook.net/en_US/all.js”;

    d.getElementsByTagName(‘head’:wink:[0].appendChild(js);

    }(document));

    </script>

    <div id=”fb-root”></div>

    <script>(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/en_US/all.js#xfbml=1&appId=225931447432843”;

    fjs.parentNode.insertBefore(js, fjs);

    }(document, ‘script’, ‘facebook-jssdk’:wink:);</script>

    <div class=”fb-comments” data-href=”http://www.localsave.co.uk” data-num-posts=”20″ data-width=”500″></div>

  • harryhayes
    • The Incredible Code Injector

    Strike last comment. Was working, but it has now disappeared from the page?

    I gather that it is simply adding a comment stream that auto updates to facebook so it is great for a bit of free publicity.

    I am going to take a look at Ultimate Facebook – you have so many plugins!

    I will update when I work out what went wrong.

    -Nick

  • harryhayes
    • The Incredible Code Injector

    Update.

    OK -Your Ultimate Facebook plugin will allow this and then some but just to close up I found the following.

    1. The code only seems to allow comments to be made on your page and about the content of. The comments appear to be auto loaded to your facebook page, however, they don’t appear to get posted to your wall which is a shame as it would be very handy if it did. (I will explore this more but this I will just install Ultimate facebook instead).

    I you still want to use this, post code (with your facebook app id and website url) as html in any post or page.

    BUT you must only add text between the break in the code as shown below. Code above must remain unchanged to work.


    ………………………..}(document, ‘script’, ‘facebook-jssdk’:wink:);</script>

    INSERT PAGE EDITS HERE OR IT WILL BREAK

    <div class=”fb-live-stream” data-event-app-id=”your app id here” data-width=”400″ data-height=”500″ data-always-post-to-friends=”false”></div>


    I think this might be useful for a quick way to gather data but I suspect, (and will try), that the Ultimate Facebook plugin will be more useful.

    -Nick

  • Timothy
    • Chief Pigeon

    Hey Nick.

    The information your might be looking for to order comments:

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

    Social Relevance: Comments Box uses social signals to surface the highest quality comments for each user. Comments are ordered to show users the most relevant comments from friends, friends of friends, and the most liked or active discussion threads, while comments marked as spam are hidden from view.

    I see you found the Ulitmate Facebook plugin. :slight_smile:

    Take care

  • harryhayes
    • The Incredible Code Injector

    Hi & Thanks Tim. It is exactly what I was looking for.

    Learning all the time.

    I’m just installing the Ulitmate Facebook plugin which would probably have saved me a lot of time and effort in the first place.

    I have been using Joomla for the last year and switched to WP only recently. I guess I am still getting used to the fact that everything WP seems to have an obvious and often simple solution.

    Wish I had made the change long ago.

    -Nick

  • Timothy
    • Chief Pigeon

    Joomla is pretty cool, just very complex in its approach to how you manage the website. When I think about Joomla it always reminds me of client that is not a tech type person and they prefer Joomla over WordPress because they see WP as being complex.

    I guess because they were introduced to Joomla years ago, they got set in their ways.

    I’ve used WP since about 2005. Right in with the WPMU version first, but my main systems were not WP as I had active business and social interests in another Open Source project which was then forked (again).

    WP is now my main interest and has been for a while. :slight_smile:

    Anyway, I babble on. lol

  • harryhayes
    • The Incredible Code Injector

    To be honest, if I had the money, I would not use any, it’s driving me half mad with the amount of reading I have to do just to resolve simple issues. lol. I can’t even get a transparent header image to work in gridmarket at the mo!

    The one consolation I have, is there seems to be a good, (and friendly), support system around WP whereas the Joomla community, as good as it is, sometimes seems far less responsive to the uninitiated. (in my opinion).

    Just when I had finally got my head around Joomla, I was shown WP and since, I have managed to reproduce a site I made in Joomla, (which took the full year), in just a few days so maybe having started this way has actually helped me in the long run.

    Anyway, after finding this site and these plugins, I intend to stick with it. I will just have to accept my lack of knowledge will mean more sleepless nights but at least I am having fun and progressing at last. :slight_smile:

  • Timothy
    • Chief Pigeon

    Hey again.

    I can’t even get a transparent header image to work in gridmarket at the mo!

    Not sure what issue you are having there, do you have a screenshot? Is it a png your using?

    The eco system around WP is pretty good. And there are tons of tutorials, documents and a pretty cool codex to help out with learn stuff. I often use WP in projects for clients. :slight_smile:

  • harryhayes
    • The Incredible Code Injector

    Hi Tim

    Not sure what the issue is, sometimes the image doesn’t seem to upload into the gridmarket theme header options even though it appears in the media library. When it does upload, it crops incorrectly and appears with a black background.

    I have read about saving as transparent 24bit png etc, but try as I might, no success with transparency or quality.

    Screenshot attached ( I think) or see http://www.st.albans.biz

  • harryhayes
    • The Incredible Code Injector

    Hi, UK yes but I think I would rather be in sunny Surfers Paradise supping tinnies.

    Tried image size, but no success. However, I don’t think I have tried it as a png24 as I have only just discovered this bit.

    Trying now.

    1.45 am, guess you don’t sleep either?

  • Timothy
    • Chief Pigeon

    No worries, just glad I could help. :slight_smile:

    1.45 am, guess you don’t sleep either?

    Often not. lol

    I’m catching up on some work and following some threads I’m involved in here, I was out of the office most of the day thanks to my car, the keycard stopped working so my immobiliser wouldn’t turn off and the neither would the steering lock. Had to wait for the AA to take it to the garage, they kept getting delayed. £170 for a new key, its only like a memory stick type thing. Darn Renault cars and their ridiculously priced keys!!!

  • harryhayes
    • The Incredible Code Injector

    Hey I envy your imminent arrival. I remember it well. I didn’t come down for weeks, it is a great buzz.

    My first was a similar time of year too. Enjoy it, nothing even comes close.

    Managed three weeks in Spain last year but I am hoping the project I am working will prove successful enough for me to work where and when I like but I have a long haul ahead.

    It’s been an awful year but things are looking up finally especially if I can get this working. 40 sites in total – what a nightmare!

  • Timothy
    • Chief Pigeon

    Hey I envy your imminent arrival. I remember it well. I didn’t come down for weeks, it is a great buzz.

    My first was a similar time of year too. Enjoy it, nothing even comes close.

    Excited would be an under statement, we had been trying for a long time. So this little bundle of magic is extra special for us. :slight_smile:

    Managed three weeks in Spain last year but I am hoping the project I am working will prove successful enough for me to work where and when I like but I have a long haul ahead.

    Well I wish you luck with everything. Dreams of our own making are always possible with a little hard work and persistance. I’m sure you will do just fine. :slight_smile:

    It’s been an awful year but things are looking up finally especially if I can get this working. 40 sites in total – what a nightmare!

    Sorry to hear about that. But it will soon be a new year with new opportunities! :slight_smile:

    £170 ! just what you need right now.

    Well… Its not been a bad year for us, my business has been good and the the wife is her own boss as well, she does Wedding Photography. So although its not great or ideal, I see it that we have our health, a baby on the way so its only money and we can make more of that.

    I have had a similar day, internet stopped working on laptop and it took 4 hours to resolve. I still have no idea what caused it. What a waste of time.

    Always a nightmare, Virgin Media’s super hub has been a pain for us over the last couple of months. Constantly needing a re-boot….. down the stairs. lol. :slight_smile:

    Take care.

  • harryhayes
    • The Incredible Code Injector

    All too true.

    Interesting you say Virgin Hub. I use Virgin but with Apple wireless and I have been having the same problem for several weeks. Maybe it’s not my kit after all.

    I am smiling at the memories of those first few moments holding the baby. Enjoy every moment you can. I know it sounds like a cliche but it really does go by fast.

    Hope it all goes down well.

    Thanks again and have a great Christmas.

  • Timothy
    • Chief Pigeon

    Hey

    Interesting you say Virgin Hub. I use Virgin but with Apple wireless and I have been having the same problem for several weeks. Maybe it’s not my kit after all.

    We get it on Mac, Linux and Microslow. The best thing to do is turn the router into modem only and use a separate router.

    I am smiling at the memories of those first few moments holding the baby. Enjoy every moment you can. I know it sounds like a cliche but it really does go by fast.

    I know, everything goes all to fast :slight_frown: But I’ll cherish every moment. :slight_smile:

    Thanks again and have a great Christmas.

    Your very welcome, have a great one as well! :slight_smile:

  • Philip John
    • DEV MAN’s Apprentice

    Another one from the UK. We are going to take over these forums soon. :wink:

    Huzzah! Slowly but surely….

    Darn Renault cars and their ridiculously priced keys!!!

    Been there, done that. Just had my Clio looked at after 5 months off the road ’cause I got too annoyed with it being an idiot. Tsk!

  • Timothy
    • Chief Pigeon

    Huzzah! Slowly but surely….

    :slight_smile:

    Been there, done that. Just had my Clio looked at after 5 months off the road ’cause I got too annoyed with it being an idiot. Tsk!

    The AA mechanic kept saying its the French way of getting revenge. Made me chuckle, but I think he believed it, he seemed deadly serious.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.