How To Use And Configure WordPress Widgets – Part 2

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

Using WidgetsIn Part One of this step-by-step tutorial series, we explained the basics of using WordPress widgets.

In this section you are going to configure several WordPress sidebar widgets.

How To Configure Sidebar Widgets

By default, your site comes with a number of built-in widgets that can be used out of the box with little to no configuration required, such as widgets that let you display links to your pages, recent posts, text or HTML banners, adding tag clouds, etc.

By default, your site comes with several pre-installed widgets

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

Adding Sidebar Widgets In WordPress: Tutorial

In this tutorial, you will add, configure and reorder various commonly-used WordPress widgets, including:

  • Adding a clickable Support image linking visitors to your contact page.
  • Adding a Categories section with a drop down menu.
  • Add a Recent Posts section to display the latest posts.
  • Adding a list of the site’s Pages.
  • Display Links on the sidebar area.
  • Display the latest news with an RSS Feed section.
  • Adding tag links with a Tag Cloud.
  • Adding and configuring an Archives section to your sidebar navigation area.

The Widgets panel is located inside the WordPress admin area and can easily be accessed from the WordPress administration menu by clicking on Appearance > Widgets

Understanding WordPress For Newbies: About WordPress Widgets

(Widgets Menu)

This brings up the Widgets section in your browser …

Widgets Area

(Widgets Section)

Let’s begin by configuring WordPress text widgets …

Add A Text Widget

Text widgets are versatile …

Text widget

(WordPress Text widget)

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 can be used to add quotes, ads, forms and more to your site … just by typing in text or inserting HTML into the widget content area. You can also give the widget a title. Remember to save your settings when done …

Text widgets are really versatile

(A text widget is versatile!)

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

For this example, let’s set up a help button on your sidebar navigation menu 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 “help button” graphic image that visitors can click on …

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

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

Using A Text Widget To Add A Clickable Support Button To The Sidebar Section

Step 1 – Upload your image.

To display an image on your site, you must first upload the graphic image to the images folder in your server and note 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 someone to be taken to the contact page when they click on the support button, you will need to either create a contact page, or have an existing destination page already set up (e.g. a helpdesk). We will link your button image to this URL in Step 3

Step 2 – Create a support page.

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

Add A Support Button To The Sidebar Area Using A Text Widget

Step 3 – Compose the HTML code for your text widget.

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 the graphic image to your contact page/helpdesk.

Your code can be typed into a plain text file and will look something like this …

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

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

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

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

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

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

Go back into your Widgets screen …

Activate or deactivate widgets using drag & drop

(Widgets Panel)

Step 4 – Add a Text widget.

Add a Text widget to your sidebar in the location where your button should display.

In the Available Widgets area, find the Text widget …

WordPress text widget

(WordPress text widget)

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

Drag and drop your WordPress text widget

(Drag-and-drop your WordPress text widget)

Step 5 – Configure your widget.

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

WordPress text widget

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

WordPress text widget

Useful Information

Note: Make sure to test all URLs before pasting scripts into your Text Widget, or the clickable button will not work.

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

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

Here is some text with Automatically add paragraphs box not checked …

Automatically add paragraphs box not ticked

(Automatically add paragraphs option not selected)

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

Automatically add paragraphs option ticked

(Automatically add paragraphs box checked)

***

Step 6 – Refresh the web browser.

Once you have added your widget and code content, go to your site and refresh the web browser. If you have entered all of the links correctly, then your clickable support button should display at the top of your sidebar menu …

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

(Clickable support button widget on blog sidebar)

The above screenshot shows the contact button added to a newly-installed WordPress site.

Step 7 – Test your widget.

The final step is to ensure that the links work. Test your button to make sure that visitors will go to your help page when clicking the graphic image. If you are taken directly to the contact page, then your text widget has been set up correctly …

Test the text widget

(Test the text widget to make sure it works)

Practical Tip

Tips:

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

Use A Text Widget To Add A Clickable Contact Button To Your Sidebar Area

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

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

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

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

(Adjust column width or reduce image size)

More 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 support button to any URL you want (e.g. to an external site, contact form, FAQ page, etc.) and change this anytime by replacing the content inside the widget.

How To Add WordPress Widgets To The Sidebar

***

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

To continue reading, click this link:

***

"Learning WordPress has been a huge stumbling block for me. I've been looking for something that covers absolutely everything but doesn't cost an arm and a leg. Thank you so much ... you have just provided me with what I have been looking for! Truly appreciated!" - Tanya