Wordpress Shortcodes

WordPress Shortcodes

Simply put, a shortcode is a coding version of a shortcut. It is a WordPress-specific snippet of code that allow you to save time and create functionality in your WordPress site that would otherwise take a lot of time and effort. 

When you are editing a WordPress site, shortcodes such as the examples below can be dropped into any page or post (including custom posts).

  • [shortcode_name]
  • [most_popular_post]

From the WordPress.org site:

A shortcode is a WordPress-specific code that lets you do nifty things with very little effort. Shortcodes can embed files or create objects that would normally require lots of complicated, ugly code in just one line. Shortcode = shortcut.

For WordPress developers shortcodes provide a way for their plugins and themes to pass on functionality to users. Shortcodes create a bridge between the complexity of writing code and the users ability. It’s also a simpler approach to passing on functionality than say to build an entire separate interface.

Developer Resources for Creating WordPress Shortcodes

Tutsplus tutorial on WP shortcodes: http://code.tutsplus.com/articles/getting-started-with-wordpress-shortcodes–wp-21197

 


About the CMS Feature Comparison Series

CMS systems like WordPress and Drupal have so many features it’s hard to keep track of them or compare them. Often comparisons are apples to oranges, or even apples to turnips. It requires context to make comparisons of features, and we need to look at what the goal is of the given feature. In our series of CMS features comparisons we do our best to look at a useful feature of 1 CMS system and then compare it to other systems that we work with. We focus on WordPress, Drupal and Concrete5 but may include other systems in certain feature comparisons.