What is a shortcode?

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.

In general you use a shortcode by placing the opening shortcode tag and ending shortcode tag between the content you want to display.

For example, to display a drop cap of the first letter for a paragraph, you would do the following:


[ dropcap2]L[/ dropcap2]orem ipsum dolor sit amet.....

[dropcap2]L[/dropcap2]orem ipsum dolor sit amet, consectetur adipiscing elit. Nunc auctor bibendum diam in facilisis. Pellentesque accumsan, magna et auctor hendrerit, ligula justo porttitor neque, at varius metus nisi vel nulla. Integer nibh sem, eleifend eu sollicitudin nec, vestibulum sed erat.

[divider]

Reference:

  1. Leave a comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: