How To Use And Configure WordPress Widgets – Part 2

Learn how to add, configure, and use text widgets on your WordPress sidebar …

Adding WordPress Widgets To Your Sidebar MenuIn Part One of this tutorial series, we cover the basics of using WordPress widgets.

In this tutorial we are going to show you how to configure various WordPress sidebar widgets.

Widget Configuration

By default, your site comes with several preinstalled widgets, such as widgets that let you display external links, filter posts by categories, RSS feed content, filter content by publish dates, etc.

By default, your site comes with a number of preinstalled widgets

(In a default WordPress installation, your site comes with a number of active widgets)

How To Add Sidebar Widgets To WordPress: Step-By-Step Tutorial

In this tutorial series, you are going to add, configure and reorder s number of WordPress widgets to display in your site’s sidebar, including:

  • Adding a clickable Support graphic button linking visitors to the contact page.
  • Add a Categories section.
  • Add a Recent Posts section.
  • Add a list of Pages.
  • Display important Links on your sidebar.
  • Display newsfeeds with an RSS Feed section.
  • Add tag links using a Tag Cloud section.
  • Adding and configuring an Archives section to the sidebar menu.

The Widgets section is located inside the WP admin area and can easily be accessed from the admin menu by choosing Appearance > Widgets …

Understanding WordPress For Newbies: About WordPress Widgets

(WordPress Widgets Menu)

This loads the Widgets section in your browser …

Widgets Panel

(Widgets Panel)

Let’s begin by configuring a WordPress text widget …

Adding Text Widgets

Text widgets are incredibly useful …

Text widget

(WordPress Text widget)

Important Info

Rich Text Widget

From version 4.8 onward, WordPress has added native rich-text editing capabilities to text widgets …

Rich Text Widget

(Rich Text Widget)

This lets you quickly and easily format text, create lists, add emphasis, and insert links into your sidebar text …

(Format text easily with the new text widget)

Text widgets let you insert just about anything you want into the sidebar or other widget sections, such as notices, images, forms and more to your site … just type in text or insert HTML into the content area. You can also add an optional title in the Title field. Remember to save your settings …

A text widget is very useful

(Text widgets are versatile!)

Example: Using A Text Widget To Add A Clickable Support Button To Your Sidebar Menu

For this example, let’s set up a support button on your sidebar that takes your visitors to a page on your site (or an external site, e.g. a helpdesk) where they can contact you for help and support.

First, create or source a graphic image that you can use on your own site …

Using A Text Widget To Add A Support Button To Your Sidebar Navigation Menu

We’ll set up the clickable button to display at the top of the sidebar navigation area like in the example shown below …

Add A Contact Button To Your Sidebar Section Using A Text Widget

Step 1 – Upload your image.

To display the clickable image on your site, the image must be uploaded to your server. Upload your button graphic to your server and note down the address of your image location.

E.g. …

http://www.yourdomain.com/images/supportbutton.jpg

You will use this information in Step 3.

In order for visitors to go to the contact page when the support button is clicked, you must either create a contact page, or have an existing destination page already set up (e.g. a helpdesk). We will then link the button image to this URL in Step 3 …

Step 2 – Create a destination page.

Create a contact page on your site and note its URL …

Use A Text Widget To Add A Help Button To Your Sidebar Section

Step 3 – Compose your text widget code.

If you’re not a technical-minded person, don’t worry … this sounds a lot more technical than it is. In simple terms, we just need to create the instructions linking your graphic image to the contact page/helpdesk.

Your code can be written a plain text file and should look something like this …

Using A Text Widget To Add A Clickable Contact Button To Your Sidebar Navigation Area

  • Replace “http://www.yourdomain.com/contact-us” in the code above with the URL of your contact page location.
  • Replace “http://yourimagelocation.com/img/supportbutton.jpg” in the code above with the URL of your image location.

The image below shows the sections of the above sample code that you will need to replace with your actual contact details …

Add A Clickable Contact Button To The Sidebar Navigation Menu Using A Text Widget

Replace the above URLs and then copy all of the above code to your clipboard when finished.

If you need help with basic HTML code, see this tutorial:

Go back into your Widgets screen …

Activate or deactivate widgets using drag-and-drop

(Widgets Panel)

Step 4 – Add a Text widget.

Add a Text widget to your sidebar where you would like the support button to display.

In the Available Widgets area, select a Text widget …

WordPress text widget

(Text widget)

Drag your Text widget to your Active Widgets section and release it at the very top of the Widget Area …

Drag-and-drop your WordPress text widget

(Drag-and-drop your WordPress text widget)

Step 5 – Configure the text widget settings.

Click on the Text widget title bar to configure the widget settings. Paste the code with the URLs to your contact page and graphic button into your text widget content area and click save …

WordPress text widget

Add a title to the widget if you want (e.g. “Need Help?”, “Get Help”, etc.) and paste the code with the correct URLs into the Content area, then click Save when done …

WordPress text widget

Info

Note: Make sure to check your contact page and image links before pasting scripts into your Text Widget, or the clickable button will not work.

*** If using WordPress version pre-4.8 ***

If adding text with no formatting tags like paragraph breaks, you may want to tick the Automatically add paragraphs box to wrap each block of text in an HTML paragraph code (note: not required if you’re typing in formatted content like we’re doing in this tutorial).

Here is some text added to a Text widget with Automatically add paragraphs option not checked …

Automatically add paragraphs option not ticked

(Automatically add paragraphs box not ticked)

Here is some text added to a Text widget with Automatically add paragraphs box selected …

Automatically add paragraphs box selected

(Automatically add paragraphs box selected)

***

Step 6 – Refresh the web browser.

Once you have added your widget and HTML content, go to your site and refresh your browser. If all links have been entered correctly, then your support button will display in your sidebar menu …

Using A Text Widget To Add A Clickable Help Button To The Sidebar Navigation Section

(Clickable support button widget on sidebar)

The screenshot above shows the button in the sidebar of a brand new WordPress site.

Step 7 – Test the widget.

The last step is to make sure that your links work. Test the button to make sure that your visitors will go to the contact page when they click on the graphic image. You should be taken to your support page …

Test the clickable button

(Test the text widget)

Useful Tip

Text Widgets – Useful Tips:

If you would like a new window to open up when visitors go to the support page (so they don’t leave the page they’re on), then change the code from this:

Use A Text Widget To Add A Clickable Contact Button To The Sidebar Menu

To this (i.e. add the part that says: target=”_blank” in your text widget code):

Add A Contact Button To The Sidebar Navigation Section Using A Text Widget - open in new window

When choosing images for your sidebar area, make sure that the width of your image does not exceed the width of your sidebar column, especially if you are using a non-responsive WordPress theme. Note that some themes can display elements differently depending on their templates and their layout. Some sidebars are wide and some are narrow. If your theme’s sidebar is narrower than the width of your button images, then you may have to either adjust the image size, or the column width to make graphics display correctly on your sidebar.

Make sure the width of the image does not exceed the sidebar column width

(Adjust column width or reduce image size)

Extra Tips:

  • If you don’t want to center your image in your sidebar, delete the <center> and </center> tags from the beginning and end of the HTML code. The image will then be left-aligned.
  • You can link your contact button to any URL you want (e.g. to an external site, contact form, FAQ page, etc.) and change this anytime by replacing the links in your text widget.

How To Add WordPress Widgets To Your Sidebar Menu

***

This is the end of section two of this series of tutorials.

To view Part 3, click here:

***

"This is AMAZING! I had learnt about how to use WordPress previously, but this covers absolutely everything and more!! Incredible value! Thank you!" - Monique, Warrior Forum