Cake with candles on-top representing "100"

Celebrating my 100th Post!

Without even realising I have passed my 100th post here on my blog! Most of that came over the last year where my blogging really increased in terms of volume however 100 posts is actually quite small for a blog and this is due to my limited time constraints. I have really started to enjoy blogging which is something I wasn’t sure would catch on for me! I remember my very first attempts at blogging years ago on my MySpace Blog but I just couldn’t think what to blog about! I now have the problem I have too much to blog about and not enough time to write and put together the blogs!

I think the major reason for my interest in blogging since I got this blog is the fact it is my own brand/identity with my own domain and even my own short-urls! It is also thanks to WordPress which make blogging such an easy and enjoyable experience while also bringing out the web developer in me with plugins that I have started designing.

I would just like to thank all my readers over the years and to let you know that in 2011 I hope to REALLY start blogging on a regular basis with hopefully interesting and up to date content! Happy Reading!


As of version 0.3.0 there have been some changes to the syntax of the Flatr Shortcode Widget so I have rewritten this guide accordingly! There are still the 3 methods that there were before for inserting the widget however for this guide, I have simplified it down to two!

Simple

The simple method (as the name suggests) is the easiest way to add a widget to your blog posts and pages! It will use all the default settings and all you have to do is insert the code!

[flattr /]

When you use this simple widget, here is how your widget will be configured:

  • The button type will be set to large
  • The User ID will be set to the author’s flattr id (if it is set and enabled in the settings), failing that it will be set to the default flattr ID set on the settings page or through the official Flattr plugin.
  • The title will be set to the Page/Post title
  • The description will be set to the Page/Post excerpt
  • The category will be set to text
  • The language will be set to English
  • Tags will not be set
  • The url will be set to the Page/Post’s permalink
  • The thing will not be hidden from listings on flattr.com

Advanced

You can also customise this code so that you can manually set the variables when calling the shortcode.

[flattr uid='{uid}' btn='{btn}' tle='{tle}' dsc='{dsc}' cat='{cat}' lng='{lng}' tag='{tag}' url='{url}' hide='{hide}' anc={anc} setanc={setanc} qty={qty} /]

All variables are optional (defaults will be used if left blank). If, for example, you wanted the default url you could exclude all “url=’{uid}’ ” and the default would be used. Leaving a variable empty will also result in the default being used but it is probably best practise to remove variables you are not going to be using.

To use edit the shortcode you should change the parameter values (indicated with curly brackets surrounding them). The parameters are:

  • btn – This is the type of button you would like to display. To get the compact button use ‘compact’ otherwise the default (large) button is displayed.
  • uid – This is your personal user id. If not defined, it The User ID will be set to the author’s flattr id (if it is set and enabled in the settings), failing that it will be set to the default flattr ID set on the settings page or through the official Flattr plugin, otherwise the widget will fail and return an error!
  • tle – This is the title of the thing you want to submit. This is typically the title of your blog entry or software name. If undefined the title of your Post/Page will be used.
  • dsc – This is the full excerpt of the content. Some blog text or information about your song you’ve written or so forth. If undefined excerpt title of your Post/Page will be used.
  • cat – This is the flattr category the content belongs to. You can choose between the following: text, images, video, audio, software, rest. If undefined text will be used.
  • lng – Language of the submitted thing. List of available languages. If undefined Enlgish (en_GB) will be used.
  • tag – This is the tags of the thing, to help people finding your content easier on the Flattr website. If you want to use multiple tags, separate using a normal comma (,) sign. If undefined no tags will be used.
  • url – This is the URL of the thing, if this is not always the same on your site. Maybe you have multiple domains with the same content. This is to lock the content to always be recognized as the same content for Flattr. If undefined the permalink of your Post/Page will be used. If you have an anchor that you want to append, it would be best practice to append it using the ‘anc’ parameter.
  • hide – Use this to hide the thing from listings on flattr.com. The value ‘true’ or ‘t’ will hide the thing. If undefined the the thing will be shown on listings on flattr.com.
  • anc – Appends an anchor to the url (saves you having to write the whole URL just to add an anchor). If a unique anchor is used on each widget it allows for multiple widget on the same URL. This must be unique otherwise 2 widgets with the same ‘url’ and ‘anc’ they will be the for the same flattr. Default is blank.
  • setanc – This value is ignored if no anchor is set, if it is set then it will add a code to the top of the widget so that the defined anchor redirects to the widget’s location. This means that when people follow the link from flattr.com, they will be taken to the location of the widget on the page. This is good if you want to have multiple flattrs for different sections and you put the flattr widget at the top of each section. Set to ‘1’ to set to true, ‘0’ to set to false. Set to false if you want to manually input the anchor code (if for example you wanted it elsewhere rather than at the point of the widget or you just wanted the backlink from flattr.com to go to your page as normal)
  • qty – Allows for you to have as many Flattr widgets as you want. Whatever number you set the value to will be the ammount of unique flattr widgets that will be created. Uses anchors to make them unique and is compatible with the ‘anc’ variable – it may cause problems if an anchor is set in the ‘url’ variable. Default is ‘1’.


Earlier today I released the 0.2.0 build of the Flattr Shortcode Widget and it includes a whole bunch of new features as well as a couple of minor bug fixes!

Click here to go to the download page.

New Features

New features include Anchors and Multi-Flattr which bring extra functionality which can be timely to manually set up and are not yet offered by any other widget.

Anchors

The main purpose for the anchors feature is to allow you to enable users to flattr sections of a page individually. Previously this was difficult as working around the limit of one flattr per url is tricky. The new feature adds an additional variable, ‘anc’ that can be set to easily give each a flattr widget their unique identifier. When you have set the ‘anc’ variable, you are also then able to define the ‘setanc’ variable. If this is set to true, then an anchor will be placed before the widget that is inserted. This will mean that when the backlink from flattr is followed, they are taken straight to the widget. If you want to set the exact location of the anchor by manually adding the code or just want this disable then make sure ‘setanc’ is false.

Eample:

This feature also allows you to create (and be given) multiple flattr’s allowing (if you feel you deserve it) for people to give you more than one of their flattrs. You could manually set up lots of widgets with different anchors but whether you are setting lots of variables in each or just lots of basic widgets this will become time consuming and difficult to manage so I created the created the Multi-Flattr feature.

Multi-Flattr

This is a very simple new feature that allows you to generate more than one flattr widget that exploit the anchors feature to make each unique so that each is unique. If no ‘anc’ is set then the ‘anc’ will be set to a range of numbers (however the first widget will have no number so to avoid problems with any other widgets you may put on the page you can set the ‘anc’). If you have set the ‘anc’ then  the unique number will be appended to the end of it.

This feature allows you to generate unlimited flattr widgets, that are all unique meaning you can give users the option to flattr you as many times as you feel you deserve! To use this feature all you have to do is define how many widgets you want with

Example:

Change Log

0.2.0

  • NEW: Anchors added so that multiple flattrs can be used on the same URL
  • NEW: Your backlink from flattr can link straight back to the widget rather than just back to the page (uses anchors)
  • NEW: You can define how many flattr widgets you want to be generated and each work independantly (allows multiple flattrs)
  • NEW: You can use multiple flattrs and anchor features simultaniously
  • UPDATE: All true/flase values must now be set to ‘1’ (true) or ‘0’ (flase)
  • BUG FIX: Hide not always set to true
  • BUG FIX: Default language now works
  • UPDATE: Arrays now used instead of lots of independant variables
  • BUG FIX: Whitespace in variables that would cause the widget to fail is now removed

0.1.4

  • BUG FIX: Decription was not filled in if not manually set and was therefore required

0.1.3

  • BUG FIX: Problems with svn sync fixed
  • BUG FIX: Version numbers corrected

0.1.2

  • UPDATE: Widget name changed from “Flattr Widget” to “Flattr Shortcode Widget”

0.1.1

  • UPDATE: Major updates to readme.txt
  • NEW: Added to WordPress Plugin Directory
  • BUG FIX: Bug that interfered default size of widget for official plugin has been corrected

Bugs

Please report bugs in the comments

Known Bugs

  • Anchor’s <a> tag is not closed. (Fixed in update 0.2.1)

Features

If there are any features you would like then please request them in the comments

Features in development

  • Configuration page with custom default settings
  • Graphical shortcode generator


Just thought I would quickly sum up how to use the Flattr shortcode for a ‘thing’ that you have already added to flattr.com. It is really simple, all you need to do is set the “url” variable! Nothing else needs to be set (unless you want to customise the btn type).


Okay so one of the previous builds (0.1.1) might have been a little unstable. It was all caused after I got into the WordPress Plugin Directory. I was having difficulty getting used to how the svn system worked and it resulted in me uploading an unstable build without testing it! This latest build has been tested and double tested for all the previous bugs I had and I am now happy to say that I just updated to build 0.1.4 and that it is bug free as far as I know!

To also help reduce future problems I am going to set up a private testing blog that I can use to test plugins without giving this site downtime!

Click here to go to the download page.

Change Log

0.1.4

  • BUG FIX: Decription was not filled in if not manually set and was therefore required

0.1.3

  • BUG FIX: Problems with svn sync fixed
  • BUG FIX: Version numbers corrected

0.1.2

  • Widget name changed from “Flattr Widget” to “Flattr Shortcode Widget”

0.1.1

  • Major updates to readme.txt
  • Added to WordPress Plugin Directory
  • Bug that interfered default size of widget for official plugin has been corrected

Bugs

Please report bugs in the comments

Known Bugs

  • None

Features

If there are any features you would like then please request them in the comments

Features in development

  • Configuration page with custom default settings
  • Graphical shortcode generator
  • Add a unique ID system so that multiple Flattrs can be used for the same URL


The WordPress Flattr Widget that I posted earlier today, is now listed here in the WordPress Plugin Directory and has a new name “Flattr Shortcode Widget”. This change in name was made to stop confusion between the official Flattr Widget and this one. This newer version contains some bug fixes so it will be worth updating!

Click here to go to the download page.

Change Log

0.1.2

*Widget name changed from “Flattr Widget” to “Flattr Shortcode Widget”

0.1.1

*Major updates to readme.txt
*Added to WordPress Plugin Directory
*Bug that interfered default size of widget for official plugin has been corrected

Bugs

Please report bugs in the comments

Known Bugs

  • Automatic update does not work
  • Description is a required variable

Features

If there are any features you would like then please request them in the comments

Features in development

  • Configuration page with custom default settings
  • Graphical shortcode generator
  • Add a unique ID system so that multiple Flattrs can be used for the same URL


Here it is, my first ever plug-in for WordPress. Please note that this is a very early release beta and there may be bug and there will be improvements to be made.

Click here to Download Version 0.1

Description

This is a widget that allows you to quickly and easily create a flttr widget within posts and pages using a simple shortcode. The advantage of having a shortcode is that it can be customised for every use. The short code has lots of customisability and can be used in a very basic way or with more advanced features.

The way the widget works is that within a post or page you include the shortcode and then that shortcode will generate all the javascript needed to embed the widget. That means you don’t need any knowledge of coding or js. As opposed to the official Flattr Widget, you do not need to embed a php function to get the widget or have it included in every post. You can call the shortcode from within a post or page and the most important thing is that you have the option to customise the widget every time! This does not mean that the official Flattr Widget does not have its place, and I actually recommend using both in conjunction!

This means that you can insert widgets that will Flattr pages other than the one you are on (for example some external content) and it will also allow you to set the Flattr User ID per widget meaning you can have multiple widgets for multiple people, or allow blogs that have multiple authors to add a Flattr widget that will flattr them (rather than the site) for their content.

How to Use

There are a few ways that the Widget can be used going up in complexity.

Super Simple (Requires official Flattr Plugin)

Super Simple Shortcode

Super Simple Shortcode

There are various ways that the Flattr Widget can be used. The most simple is to just include the code in the image on the right anywhere in a post. Using this will require that you have the official Flattr Widget installed and have set your Flattr UID on that (an independent setting will come in a later version).

Settings will be automatically set as stated:

  • The button type will be set to large
  • The User ID (as mentioned above) will be set to that which is set up in the official plugin
  • The title will be set to the Page/Post title
  • The description will be set to the Page/Post excerpt
  • The category will be set to text
  • The language will be set to English
  • Tags will not be set
  • The url will be set to the Page/Post’s permalink
  • The thing will not be hidden from listings on flattr.com

In a future build, some of these default settings will be customisable.

Simple

Simple Shortcode

Simple Shortcode

Simple is the most simple way of using my Flattr Widget if you do not have/want to install the official Flattr Plugin. It is also what you would use if you have multiple bloggers blogging on the same blog and each want to earn their own Flattry. To use this option, use the code shown in the image on the left replacing {uid} with your Flattr User ID. The only difference between this simple option and the super simple option is that you are defining your Flattr User ID independently.

Settings will be automatically set as stated:

  • The button type will be set to large
  • The User ID will be set to whatever you have defined as {UID} in the shortcode
  • The title will be set to the Page/Post title
  • The description will be set to the Page/Post excerpt
  • The category will be set to text
  • The language will be set to English
  • Tags will not be set
  • The url will be set to the Page/Post’s permalink
  • The thing will not be hidden from listings on flattr.com

In a future build, some of these default settings will be customisable.

Advanced… but still pretty simple!

Finally, there is the advanced option. You can use the advanced shortscode shown bellow. All variables are optional (defaults will be used if left blank). If, for example, you wanted the default url you could exclude all ” url='{uid}’ ” and the default would be used. Leaving a variable empty will also result in the default being used but it is probably best practise to remove variables you are not going to be using. Note that if you do not set {uid} you do not need the final “[/flattr]“

Advanced Shortcode

Advanced Shortcode

To use edit the shortcode you should change the parameter values (indicated with curly brackets surrounding them). The parameters are:

  • btn – This is the type of button you would like to display. To get the compact button use ‘compact’ otherwise the default (large) button is displayed.
  • uid – This is your personal user id. If not defined, it will be set to that which is set up in the official plugin providing that is set up and installed, otherwise the widget will fail!
  • tle – This is the title of the thing you want to submit. This is typically the title of your blog entry or software name. If undefined the title of your Post/Page will be used.
  • dsc – This is the full excerpt of the content. Some blog text or information about your song you’ve written or so forth. If undefined excerpt title of your Post/Page will be used.
  • cat – This is the flattr category the content belongs to. You can choose between the following: text, images, video, audio, software, rest. If undefined text will be used.
  • lng – Language of the submitted thing. List of available languages. If undefined Enlgish (en_gb) will be used.
  • tag – This is the tags of the thing, to help people finding your content easier on the Flattr website. If you want to use multiple tags, separate using a normal comma (,) sign. If undefined no tags will be used.
  • url – This is the URL of the thing, if this is not always the same on your site. Maybe you have multiple domains with the same content. This is to lock the content to always be recognized as the same content for Flattr. If undefined the permalink of your Post/Page will be used.
  • hide – Use this to hide the thing from listings on flattr.com. The value ‘true’ or ‘t’ will hide the thing. If undefined the the thing will be shown on listings on flattr.com.

Download

Click here to Download Version 0.1

Flattr Me

If you use my plugin, you can show your appreciation by flattring me:

Bugs

Please report bugs in the comments

Known Bugs

  • Can affect the size of some of the widgets created using the official plugin (change some from large to compact)

Features

If there are any features you would like then please request them in the comments

Features in development

  • Configuration page with custom default settings
  • Graphical shortcode generator


That’s right, I have made my first WordPress plugin and I must say, it wasn’t too hard at all! Sure, what I have made is very basic but making plugins seems simple enough so you might want to expect a few more! I will be posting a blog with the link to download the new plugin that is designed to make on-the-fly integration between your WordPress pages and posts even easier. UPDATE: Plugin now posted!

Currently the plugin will be hosted here, on my servers but I am currently trying to get it onto the WordPress Plugin Directory. Since this is my first plugin I am not 100% sure about what is happening with that but from what I can tell, I am just waiting for my plugin to be approved as it is listed as a request and the svn directory has not been created for me.


After reading a blog post that I found when it was ReTweeted by @windowsphone, I discovered the Odiogo plugin for wordpress. It is a nifty little plugin that you can install onto your wordpress blog which allows your, more lazy readers have each blog post read to them.

What you get is the standard sort of robotic voice (after a little Odiogo jingle for branding 😉 ) reading the blog post. The quality is quite good and can be very fluent at times but is nowhere near perfect. It does try and be natural but siome times the tone used is all wrong and in very logn sentences where a pause would be used even where there are no commas, the reader picks up in pace and it becomes very fast!

The main problems comes when you start having abreviations for things or non-english words (which is very often on a technology blog like this). Sometimes it will try and make the abreviations into a word rather than spelling it letter by letter and other times you get the oposite; you may have a word in capitals which it assumes is an abreviation and so reads letter by letter!

Overall the Odigio plugin is a nice feature which I will leave running but it is nowhere near perfect!


This blog is simply a personal experiment and may be of no interest to you unless you too have a WordPress blog and ask yourself the same question:

Often I post a blog post without updating the permalink to something sensible. This means that after posting I have to change the permalink, and this could mean that the links posted on other sites automatically (like the link automatically posted on my twitter) may point to the wrong place. But what I want to know is whether when you change the permalink, the old permalink still exist, so that the the link is not broken? I will test this theory on this blog and let you all know with an update to the blog 🙂

UPDATE: Well that was simple enough, and I know have my answer 🙂 If you update your permalink after publishing, the old permalink will redirect to the new location meaning that no links are broken! However, it did appear that the TweetMeme ReTweet widget reset to 0 when doing this!

[cb type=”product”]WordPress[/cb] [cb]TweetMeme[/cb]