
Putting a Facebook Like Button in a Movabletype Blog


Image via Wikipedia

The top of this post has a Facebook "like button." I'm not sure I'm going to leave it there, but I though I'd share how I did it. These instructions are for Movabletype:

  1. Edit the "Individual Entry Archive" template under "Archive Templates"
  2. Once you decide where you want the button in the template, insert the following code: Note that <$MTEntryPermalink$> is what gets the entry URL and places it in the call to Facebook
  3. Save the template
  4. Republish any entries you want to have the like button

You might want to change how the Facebook like button looks. You can do that on Facebooks like button generator page. Just remember to change the URL to use <$MTEntryPermalink$>. I had to add a "height: 25px" to the iframe style to make it the right height. Still not sure this is right, but without it, I got a big white space underneath the iframe.

Pretty simple and now your blog has been assimilated by Facebook.
{"cc_re__cc_re__cc_by_sa_3_0_en": ["eign Authorities and the Epic Struggle for IoT</a></li>\n  <li><a href='/archives/2014/09/events_picos_and_microservices.shtml'>Events, Picos, and Microservices</a></li>\n  <li><a href='/archives/2014/09/a_university_api.shtml'>A University API</a></li>\n</ul>\n               </div>\n           </div>\n           </div>\n           <div class=\"row\">\n              <div class=\"span12\">\n                 <div class=\"copyright\">\n                    <p class=\"pull-right\">&copy; 2002-2013 Phillip J. Windley. <a rel=\"license\" href=\"http://creativecommons.org/licenses/by-sa/3.0/deed.en_US\">Some rights reserved</a>.<br/>Technometria is a trademark of PJW LC.</p>\n                    <p class=\"pull-left\">\n                      <a href=\"http://www.twitter.com/windley\" rel=\"tooltip\" title=\"Twitter\" class=\"sb circle twitter\"></a>\n  \t\t      <a href=\"http://github.com/windley\" rel=\"tooltip\" title=\"Github\" class=\"sb circle github\"></a>\n  \t\t      <a href=\"http://www.linkedin.com/in/windley\" rel=\"tooltip\" title=\"LinkedIn\" class=\"sb circle linkedin\"></a>\n            \t      <a href=\"/rss.xml\" "], "copyright__copyright__copyright": [" 3. Save the template\n  4. Republish any entries you want to have the like button\n\nYou might want to change how the Facebook like button looks. You can do that on Facebooks like button generator page. Just remember to change the URL to use <$MTEntryPermalink$>. I had to add a \"height: 25px\" to the iframe style to make it the right height. Still not sure this is right, but without it, I got a big white space underneath the iframe.\n\nPretty simple and now your blog has been assimilated by Facebook."]}