13 February 2024

20 WordPress Shortcodes and Plugins You Should Definitely Try

By Ronald Smith

If you’re new to the whole idea of shortcodes, let me break it down for you. A shortcode is a fancy bit of code that you can use on your WordPress site to do all sorts of cool things. And the best part? You don’t have to clutter up your content with long, messy lines of code. With a shortcode, you can condense it all into a single line!

In simple terms, a shortcode is like a magic trick. It’s a clever little shortcut that saves you from having to write out a long and complicated script or code. Sure, WordPress comes with its own set of shortcodes, but why stop there? There are so many more options out there, offering even more flexibility and creative possibilities.

Did you know that you can customize your blog theme or use a plugin to add cool features to it? It’s true! Shortcodes are these little codes that you can insert into your blog to make it do special things. You can add them manually or use a plugin to make it easier. The only tricky part is finding the right plugin that matches what you want to do on your blog. But don’t worry, I’ve got you covered! In this post, I’ll show you 10 awesome WordPress plugins that will give your blog shortcode superpowers. And as a bonus, I’ll also give you 10 shortcode codes that you can add yourself.

50 Awesome WordPress Plugins You Should Know

Blogging has become super popular these days, and with so many tools and plugins available, it’s easier than ever to create an amazing blog. If you want to take your blog to the next level, check out these 50 useful WordPress plugins. They’ll make your blog stand out from the crowd!

WordPress Plugins

If you’re using WordPress, you’re in luck! There are tons of plugins that let you use shortcodes or even create your own. I’ve rounded up some of the best ones for you. And just in case one doesn’t work for you, I’ve also included an alternative plugin that does pretty much the same thing. So without further ado, here they are:

Shortcode

Hey there! Let me give you the scoop on this awesome plugin called WordPress Shortcodes. It’s a super handy tool for adding some pizzazz to your blog posts. Let me break it down for you by explaining what each shortcode does:

1. [postcountbr]: This little guy displays the total number of published blog posts. It’s perfect for showing off how much content you’ve got.

2. [catcountbr]: This nifty shortcode shows the total number of categories that have at least one post in them. It’s a great way to organize your blog.

3. [tagcountbr]: This one’s a winner if you want to display the total number of tags that have at least one post attached to them. It’s all about keeping things organized, my friend.

4. [totalwords]: Want to know how many words you’ve written in all your glorious posts? Just use this shortcode and presto! The total word count appears like magic.

5. [commentcount]: This is the one you’ll want to use to display the total number of approved comments on your blog. It’s great for showing how engaged your readers are.

6. [pagecount]: Last but not least, this shortcode displays the total number of published pages on your blog. It’s a neat way to keep track of your site’s structure.

But wait, there’s more! This plugin goes above and beyond by giving you over 20 additional shortcodes and an easy-to-use shortcode editor. With these, you can really take your blog to the next level. Here are just a few of the cool elements you can add:

– SEO-ready tabs and buttons: Let your readers navigate your content with style.

– Author cards: Give credit where credit is due and showcase your awesome contributors.

– Message boxes: Make important announcements or highlight key information with eye-catching boxes.

– Smart links: Create interactive links that lead to specific sections of your blog. Pretty neat, huh?

– Sections: Break up your content and make it even more reader-friendly.

– Lists and more: Spice up your posts with fancy lists and other cool elements.

So there you have it! WordPress Shortcodes is the secret weapon you need to make your blog totally rad. Go ahead and give it a whirl – your readers will thank you!

You can even merge multiple embedded codes within each other to form exceptional elements, such as a series of buttons or hyperlinks.

20 WordPress Shortcodes and Plugins You Should Definitely Try

Additional Information: There are two plugins that are similar to the one mentioned, and they are J Shortcodes and Arconix Shortcodes. These plugins also provide a range of helpful shortcodes that enable you to create various elements such as content and information boxes, buttons, tabs, accordion panels, toggles, and more.

Shortcodes for Post Content

This plugin introduces two shortcodes:

[post-content] – allows you to display the content of a single post or page within another post or page. To specify the post ID, you must include an argument within the shortcode. Additionally, you can utilize arguments to present a featured image, post excerpt, and post title.

[post-list] – Show me some posts! That’s what the post-list shortcode does. It’s like a magic wand that displays a list of posts right within another post. But wait, there’s more! You can customize the list to your heart’s content. You can choose the order in which the posts appear, specify which types or statuses to include, show images and excerpts, and so much more. And get this, you can even fetch posts from a different blog by using its ID as an argument in the shortcode. How cool is that?

But that’s not all: Imagine you want to display a list of attachments within a post. No worries, we’ve got just the thing for you. Check out the List Attachments Shortcode plugin, created by the same developer. It’s like having a cherry on top of your favorite dessert.

Shortcoder

Let me introduce you to Shortcoder. It’s a superhero among plugins because it lets you create your own custom shortcodes with ease. With its visual editor, you can wave goodbye to coding headaches and say hello to a world of possibilities. But that’s not all! Shortcoder also lets you store frequently used text, HTML, and JavaScript snippets, so you can access them whenever you need to. And if you’re a fan of the blog editor, rejoice! Shortcoder has a tinyMCE button that lets you insert your custom shortcodes directly from the editor. It’s like having a sidekick that makes your life so much easier.

20 WordPress Shortcodes and Plugins You Should Definitely Try

Hey there! If you’re in need of something like this, you should totally check out the Shortcode Manager. It’s a fantastic tool that allows you to create, manage, import, and export shortcodes effortlessly.

Erase Unfortunate Accidents

Sometimes, we all mess up. And hey, we’ve all accidentally disabled shortcodes, which can mess up their functionality. But don’t worry, I’ve got a solution for you! Instead of going through each page or post to remove these “broken” shortcodes manually, why not just hide them? This plugin does exactly that, and it’ll make your life way easier.

Got more questions? Hide Unwanted Shortcodes is another plugin that gets the job done. It ensures that those broken shortcodes don’t show up on your site, so you can easily edit them directly from the plugin’s settings page. Simple as that!

Get Creative with Columns

20 WordPress Shortcodes and Plugins You Should Definitely Try

If you’re searching for a plugin that helps you create a responsive column grid for your posts and pages, check out the Metaphor Shortcodes plugin. With this plugin, you can easily customize your columns by specifying attributes like span, start, end, and class. In addition to the column grid feature, this plugin also offers a range of other useful shortcodes. These include the Post Block Shortcode, which lets you display the title and excerpt of any post type anywhere on your blog. The Post Slider Shortcode enables you to create a horizontal slider of any post type and display it within your content. Lastly, the Pricing Table Shortcode empowers you to create various pricing tables to showcase in your content. So, give the Metaphor Shortcodes plugin a try if you’re in need of a versatile and user-friendly plugin for managing and styling your content.

Hey there! Have you heard of ShortCodes UI? It’s an awesome plugin that lets you create and use shortcodes in a super easy way. You can add these handy codes to your posts and pages, whether you’re using the visual editor or the HTML editor.

ShortCodes UI is perfect for beginners who aren’t too familiar with coding. It’s super user-friendly, and there are even some video tutorials available to help you get started. But don’t worry, if you’re a bit more experienced with code, you’ll still love the plugin! It includes a syntax highlighting code editor that you’ll definitely appreciate.

Another cool feature of ShortCodes UI is the import/export capability. This means you can easily move your shortcodes from one site to another, or even share them with your friends. It’s a great way to save time and share your awesome creations.

20 WordPress Shortcodes and Plugins You Should Definitely Try

Last Updated Shortcode

Hey there! I’ve got a super easy plugin that lets you jazz up your posts and pages with a cool feature. You just need to add the [lastupdated] shortcode, and it will automatically display the date and/or time of the last update. Plus, you have the flexibility to change how the date and time are formatted to fit your style.

Geoportail Shortcode

Check this out! I’ve got another awesome plugin that will take your posts and pages to the next level. By simply using a shortcode, you can add a dynamic Geoportail map right into your content. Cool, right? You have full control over the map size, zoom level, and even the location with latitude and longitude coordinates. You can also customize the size, territory, and layers to your heart’s content.

What’s even cooler is that this plugin supports geotagging. If you enable the Geolocation plugin, your posts will automatically reflect their location on the map. How neat is that? To make things even easier, we’ve included a shortcode builder and live preview. With this, you can create custom map shortcodes and see exactly how your map will look before hitting that publish button.

20 WordPress Shortcodes and Plugins You Should Definitely Try

Fun and Simple Shortcodes for Your Blog

Hey, folks! I’ve got some really cool shortcuts that you can use on your blog. The best part? You don’t need to install any plugins! Let me break it down for you:

  • The Meat of the Shortcode – This is a long piece of code that you’ll need to copy and paste into the Theme functions file (functions.php) of your blog. You can find this file in the WordPress dashboard under Appearance > Editor.
  • The Shortcode – You can place this code anywhere within your posts and pages to add awesome functionality.

Now, some of these shortcuts may require a little bit of customization, like adding your own Google AdSense code. So, you’ll need to know your way around code editing. But don’t worry – I’ll provide all the info you need for each shortcode.

Add AdSense Ads to Your Content

With the AdSense ads, you can easily insert ads into your content, exactly where you want them to be.

Using the Shortcode: [adsense]

Here’s the Code:

function adsense_shortcode( $atts ) {

extract(shortcode_atts(array(

‘format’ =>’1′,

), $atts));

switch ($format) {

case 1 :

$ad = ‘

‘;

break;

}

return $ad;

}

add_shortcode(‘adsense’, ‘adsense_shortcode’);

Show Related Posts

Bring attention to related posts by displaying them either above or below your content.

Using the Shortcode: [related_posts]

Here’s the Code:

    I’m going to rewrite the text you provided while keeping the HTML markup intact. Here’s my version:

    Related Posts

    I’ll show you some related posts that you might find interesting. Check them out!

    $related = get_posts( array( ‘category__in’ => wp_get_post_categories($post->ID), ‘numberposts’ => 5, ‘post__not_in’ => array($post->ID) ) );

    if( $related ) foreach( $related as $r ) {

$retval .= ‘

  • Insert PayPal Donation Link

    Add a PayPal button to make it easy for you to donate. It’s up to you!

    Shortcode: [donate]

    Code:

    function donate_shortcode( $atts, $content = null) { global $post; extract(shortcode_atts(array( ‘account’ >’your-paypal-email-address’, ‘for’ => $post->post_title, ‘onHover’ => ”, ), $atts)); if(empty($content)) $content=’Make A Donation’; return ‘ 20 WordPress Shortcodes and Plugins You Should Definitely Try ‘;

    }

    add_shortcode(‘donate’, ‘donate_shortcode’);

    Display A Google Map

    Add a Google Map to your posts to show any location you want.

    Shortcode: [googlemap src=”https://www.usamerica.com/blog/wordpress-shortcodes-plugins/google_map_url”]

    Code:

    function rockable_googlemap($atts, $content = null) {

    extract(shortcode_atts(array(

    “width” => ‘940’,

    “height” => ‘300’,

    “src” => ”

    ), $atts));

    return ‘<div class=”map-container”><iframe src=”‘ . $src . ‘” width=”‘ . $width . ‘” height=”‘ . $height . ‘” frameborder=”0″ style=”border:0″ allowfullscreen></iframe></div>’;

    }

    add_shortcode(“googlemap”, “rockable_googlemap”);

    Display External Files

    Add external files like text and images into your posts.

    Shortcode: [show_file file=”http://www.test.com/test.html”]

    Code:

    function show_file_func($atts) {

    extract(shortcode_atts(array(

    ‘file’ => ”

    ), $atts));

    if ($file != ”) {

    return file_get_contents($file);

    }

    }

    add_shortcode(‘show_file’, ‘show_file_func’);

    Add A Login Form

    Add a login form to your posts and pages, not just the sidebar.

    Shortcode: [devpress-login-form]

    Code:

    function devpress_login_form_shortcode() {

    if (is_user_logged_in()) {

    return ”;

    }

    return wp_login_form( array( ‘echo’ =>true ) );

    }

    function devpress_add_shortcodes() {

    add_shortcode( ‘devpress-login-form’, ‘devpress_login_form_shortcode’ );

    }

    add_action( ‘init’, ‘devpress_add_shortcodes’ );

    Show My Secret Notes

    Add a hidden message to your post or page that only I can see.

    Shortcode: [note]Your Message Here[/note]

    Code:

    add_shortcode( ‘note’, ‘sc_note’ );

    function sc_note( $atts, $content = null ) {

    if ( current_user_can( ‘publish_posts’ ) ) {

    return ”.$content.”;

    }

    return ”;

    }

    Content for Registered Users Only

    Add content that only people who have signed up for your blog can see.

    Shortcode: [member]Only for people with accounts[/member]

    Code:

    add_shortcode( ‘member’, ‘member_check_shortcode’ );

    function member_check_shortcode( $atts, $content = null )

    Embed YouTube Videos

    This shortcode enables you to include YouTube videos on your website. It’s not just limited to videos; you can also use it for audio and images.

    Shortcode: [youtube]Watch this amazing video![/youtube]

    Code:

    function wptuts_youtube($atts, $content=null) {

    extract(shortcode_atts(array(‘id’ => ”), $atts));

    $return = $content;

    if($content) $return .= “

    “;

    $return .= ‘<iframe width=”560″ height=”349″ src=”https://www.youtube.com/embed/’ . $id . ‘” frameborder=”0″ allowfullscreen></iframe>’;

    return $return;

    }

    add_shortcode(‘youtube’, ‘wptuts_youtube’);

    Obfuscate Email Address

    Hey there! I’m here to tell you how to keep your email safe from those sneaky spammers who scrape email addresses from web pages.

    Here’s a nifty trick you can use: make your email address unclear! That way, when spammers try to collect it, they’ll just end up confused and frustrated. How cool is that?

    Ready for the secret sauce? Drumroll, please…

    Shortcode: [email address=”[email protected]”]

    Code:

    function emailbot_ssc($attr) {

    extract( shortcode_atts( array( ‘address’ =>”, ), $attr ) );

    $email = ”;

    $email .= antispambot($attr[‘address’]);

    $email .= ”;

    return $email;

    }

    add_shortcode(’email’, ’emailbot_ssc’);