Mastering WordPress Shortcodes.: Smashing Magazine had a nice instructional writeup on mastering WordPress shortcodes and creating new ones to make one’s blogging life easier. Shortcodes are small peices of pre-determined code (viewable in the HTML version of a post) that are later expanded by WordPress when a post is published and subsequently displayed. Shortcodes are already used by WordPress for many internal functions such as albums. This tutorial goes into details of the shortcode API in WordPress and into some detail of creating advanced shortcodes to accomplish tasks such as
- Send to Twitter (or consequently, send to Techmeme via Twitter)
- Create an RSS feed link
- Insert Adsense into a post
- Insert an RSS reader into a post
- Add shortcodes to sidebars
Please let us know if you have used any of these or know of/have created others that might be useful.