-
Mastering WordPress Shortcodes
Posted on February 4th, 2009 No commentsWhat are WordPress shortcodes?
These are small snippets of code which you can embed in your WordPress post. And when you publish your post, WordPress will expand them to the corresponding HTML/XHTML code.
For example, in a blog hosted by WordPress.com, you can easily embed YouTube videos using the [
youtube=URL] shortcode. Where the URL is something likehttp://www.youtube.com/watch?v=AgEmZ39EtFk. This will embed the corresponding YouTube video into your post. You will never have to mess with the embed tags required to insert a video into your post. In fact creating your own custom WordPress shortcodes is childsplay if you know a bit of PHP.SmashingMagazine.com has a wonderful writeup on steps required to create your own custom shortcodes for your WordPress blog. The article is quite exhaustive and provides a number of examples such as “Creating a Subscribe to RSS” shortcode, “Google Adsense” shortcode, “Embedding an RSS reader” shortcode, and so on.
Related Posts
- SyntaxHighlighter – WordPress Plugin
- Top WordPress Plugins To Secure Your Blog
- Shortcut Keys Used In WordPress Editor
- WordPress Fix For A Fatal Memory Error
- How To Clean Up Your Hacked WordPress Site
