1

I am new to WordPress and I've seen this term passed around.

3 Answers 3

8

"Shortcode" is a user friendly way of inserting various WordPress plugins/scripts into a page without having to know a lot of fancy HTML/JavaScript/PHP in order to make it happen.

Take, for example, embedding an mp3 file into a post on a hosted WordPress site. Instead of having to setup the proper code for a flash player or fiddle with some fancy JavaScript, you can use the following shortcode in the editor. You don't even switch to HTML mode...

[audio: http://www.pathtomyaudio.com/song.mp3]

...and WordPress does the rest for you.

You'll find a lot of plugins for WordPress (such as Contact Form 7 and others) use this convention.

1
  • 3
    For another example, the simple shortcode [gallery] inserts a nicely formatted grid of all of the images attached to a post. It has several optional parameters but it can be used just as I typed it.
    – Andy
    Commented Mar 30, 2011 at 18:36
2

Not long ago i posted a nice explanation: Shotcodes because its shorter! It covers in short:

  • What shortcodes are.
  • How to use shortcodes.
  • How to define your own.
  • How to use them in widgets.

Worth a look.

1

These are WordPress.com specific shortcodes, but they give you an idea of the power of using them.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.