[Edit: The latest version of this plugin can be found here.]
Just a minor update to allow usage as a K2 Sidebar Module.
nb. To facilitate this, I removed the option for the plugin to output its own title – therefore the syntax involved in calling it has changed slightly – take note.
A note to new readers, this is a plugin for WordPress which lets you display the latest links from your Ma.gnolia account. You can now also display links matching one of your tags instead, if you like.
The options are, in order:
- Ma.gnolia username (required)
- Number of links to show (optional, can be any integer from 0-20, default is 10)
- Whether to show the description of each link (optional, 1 or 0, default is 0)
- Whether to show the date you published each link (optional, 1 or 0, default is 0)
- Whether to link to the Ma.gnolia page of each link, instead of the links themselves (optional, 1 or 0, default is 0)
- Whether to just show links marked with a certain tag (type the name of the tag in quotes if you want to do this, default is none)
So to just show your last 10 links, you only need supply your username:
<?php magnolia('barryprice'); ?>
Or to make it more interesting, to show the last 15 links I published, with descriptions, without dates, and linking to the Ma.gnolia page for each, I would do this:
<?php magnolia('barryprice', 15, 1, 0, 1); ?>
Or to show 20 links, without descriptions or dates, linking to the actual link URLs, we would do this:
<?php magnolia('barryprice', 20, 0, 0, 0); ?>
Of course, the default setting for those last three arguments is 0 anyway, so this would also work:
<?php magnolia('barryprice', 20); ?>
Finally, to do the same thing but only for entries tagged with “apple”, we would do:
<?php magnolia('barryprice', 20, 0, 0, 0, 'apple'); ?>