Racism

When I was in 9th grade I had an racist encounter with a white male in my grade which made me come to the realization that racism is real and still alive to this day. I was passing out papers to…

Smartphone

独家优惠奖金 100% 高达 1 BTC + 180 免费旋转




WordPress Widgets

Beginners Guide

All blogs and pages sidebars have widgets on it to show any kind of contents like social icons, ads, related posts, categories and much more. See now the complete guide for WordPress widgets usage and all you need to know about this feature.

Since WordPress is a rather straightforward platform, new users can usually figure out the basics pretty quickly.

One such mystery is WordPress Widgets.

The easiest way to put it is that a widget is a block of content (be that some text, an image or a list of links or categories, etc) that can easily be placed in specific predefined areas (known as ‘widgetized areas’) on your website. These widget-ready areas generally include your site’s sidebar, footer, header and sometimes, even an entire homepage.

By default, the WordPress core software comes with a number of different widgets that can be used in these areas:

You’re not limited to just these widgets alone, either — but I’ll get to that later.

Sounds easy enough, right? So why all the confusion?

As I mentioned above, WordPress is loaded with a set of widgets that you can choose to use or not. One reason WordPress widgets are a little confusing is that they’re not needed for WordPress to function properly — but they’re sometimes nice to have.

Another way to look at it is like this: Widgets are sort of like your appendix; we all have one, but we won’t die if we don’t. Similarly, even though WordPress comes with the function of using widgets, if you don’t put them to use on your site, it’ll still work.

But the biggest reason they tend to be confusing is that of this:

Confusing, right?

How can a plugin not be a widget, and yet, that’s essentially what some of them are? Why not split things up and have some called Plugins and others called Widgets that can be downloaded and installed just the same? Wouldn’t that make everything easier?

Well, no. And understanding this next bit makes things a little easier to see why.

As mentioned before, widgets are not needed for WordPress to function. Likewise, they’re not required for themes and plugins to function either. However, a developer can add snippets of PHP and/or JavaScript code to a particular file and create a widget to add a nice user experience for whoever uses their product.

It’s better than it all be consolidated like this than needlessly creating another category for Widgets that can be downloaded and installed on a site.

Wondering why? Here’s an example:

Let’s say you install a new Social Sharing Plugin like Monarch. After you activate it, you’ll find that there’s a new widget for Monarch that you can place in a widgetized area — a nice option to have.

But, if plugins and widgets were separate, then that would mean that the developers of Monarch would have to create two separate products — one a Plugin and one a Widget — to create a single entity and provide a better overall product.

That would also mean instead of installing one thing you would need to install two if you wanted that additional feature with that plugin. Ultimately, that would just be more work for everyone.

Since someone can use the same type of code to create a plugin as they would in order to create a widget, it makes sense to just consolidate things. So, even though some plugins and themes add widgets to your site that you can use, widgets are not something entirely separate from plugins, themes or WordPress as a whole — and for good reason too…

Mainly, just for keeping WordPress simple.

Chances are that after reading up to this point in the post, you’ve already figured out that there are a couple ways to get more widgets for your site:

Those are the easy ways to get new Widgets and widgetized areas on your website.

The other option is to hand-code a new widget in your files. That can be complicated, however, unless you’re a developer or know your way around code like PHP. Since working with PHP and adding new code to your site can really muck up the works when done incorrectly, it’s best not to mess with stuff unless you know exactly what you’re doing.

That’s why I suggest sticking with one of the two options above.

The one thing I should mention is that because widgets are integrated into some themes and plugins, deactivating a plugin or switching to another theme will remove the widgets you were using that were connected to them. So, if you stop using a plugin or change themes and notice certain widgets disappear, now you know why.

There’s one widget that comes with every WordPress install that’s a bit special — the “Text Widget“. Though the name Text Widget has an underwhelming ring to it, this widget can do more than just hold a paragraph or two.

This widget can translate any HTML you care to enter into it, which means that you can use it to hold images, create clickable links, and you can even get it to work with shortcodes.

Don’t know how to code HTML? Guess what: No problem!

Here’s a quick tip to create an HTML snippet in WordPress even if you don’t know how a thing about it:

Five easy steps and you’ve created a little something extra for a widget area on your site!

Widgets are simple both in design and concept, and yet, they’re surprisingly difficult to explain in simple terms. The good news, however, is once you’ve got your head around what they are and how they work, you’re unlikely to ever forget!

Add a comment

Related posts:

Are Nasal Strips a Gateway Drug?

When I told my father I use nasal strips at night, he was worried that it could lead to more serious drugs. “I’m not sure about that, but I do know that using nasal strips isn’t natural, and if God…

What are the Real Gifts That Matter?

How many of you are scurrying about to find the perfect gift for those in your life? Sometimes it is the white elephant gift to the office party, or perhaps it is a gift that truly reflect how deeply…

How to Read CSV and Select Rows in Pandas

As I mentioned in my earlier article, I will continue our series of articles on pandas by working with a broader data set in this article. This time, however, we will not create the database…