How To Use And Configure WordPress Widgets – Part 2

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

How To Add WordPress Widgets To Your Sidebar MenuIn Part One of this step-by-step tutorial, we cover the basics of using widgets in WordPress.

In this tutorial you will begin configuring a number of WordPress widgets.

How To Configure Frequently-Used WordPress Widgets

By default, your site comes with several pre-installed active widgets, such as widgets for displaying external links, recent posts, news items, add search features, etc.

In a default WordPress installation, your site comes with a number of preinstalled widgets

(By default, your site comes with several built-in widgets)

How To Set Up Commonly-Used WordPress Widgets On Your Sidebar Navigation Section: Tutorial

In this tutorial, you are going to add, configure and reorder s number of WordPress widgets, including:

  • Add a Support graphic button linking to your contact page.
  • Add a Categories section with a drop down menu.
  • Adding a Recent Posts section to display your latest posts.
  • Adding a list of Pages.
  • Display useful Links on the sidebar.
  • Displaying news items using an RSS Feed section.
  • Adding tag links with a Tag Cloud.
  • Configure how your Archived Posts display on your sidebar navigation section.

The Widgets section can be easily accessed inside the WP admin by going to Appearance > Widgets

Understanding WordPress For Newbies: About WordPress Widgets

(WordPress Widgets Menu)

This brings you to the Widgets area in your browser …

Widgets Screen

(Widgets Area)

Let’s start to configure some sidebar menu widgets …

Text Widgets

Text widgets are quite useful …

WordPress Text widget

(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)

A text widget can be used to add instructions, ads, scripts and more to your site … just type in text or insert HTML into the widget content area. You can also add an optional title in the Title field. Remember to save your settings when done …

Text widgets are really versatile

(A text widget is very useful!)

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

For this example, we’ll set up a clickable help button on your sidebar that will take 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 your visitors can click on …

Add A Clickable Help Button To Your Sidebar Area Using A Text Widget

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

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

Step 1 – Upload your image.

To display an image on your site, you must first upload the button image to a folder on your server and note the URL pointing to your image location.

E.g. …

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

This information will be required in Step 3.

In order for someone to be taken to the contact page when they click on the graphic button, you must either create a contact page, or have an existing destination page already set up (e.g. a helpdesk). We will then link your button graphic to this URL in Step 3

Step 2 – Create a support page.

Create a contact page and note its URL …

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

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

Don’t worry … this sounds a lot more technical than it is. Basically, you just need to create the instructions linking the graphic image to the contact page.

Your instructions can be composed in a simple text file and will look something like this …

Add A Contact Button To The Sidebar Section 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 above with the URL of your image location.

The image below shows which sections of the above sample code you will need to replace with the actual contact page and image URLs …

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

Replace the above URLs and then copy all of your text file content to your clipboard when finished.

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

Now, go back into your Widgets screen …

Activate or deactivate widgets using drag-and-drop

(Widgets Screen)

Step 4 – Add a Text widget.

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

In the Available Widgets area, find the Text widget …

WordPress text widget

(WordPress text widget)

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

Drag-and-drop your Text widget

(Drag-and-drop your Text widget)

Step 5 – Configure your text widget.

Click on the widget title bar to configure its options. 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 your widget if you want (e.g. “Need Help?”, “Get Help”, etc.) and paste the code with the correct destination links into the Content box, then click the save button …

WordPress text widget

Important

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

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

If you’re 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 paragraphs (note: this is not necessary if you type in HTML content like we’re using in the example for this tutorial).

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

Automatically add paragraphs box not selected

(Automatically add paragraphs box unchecked)

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

Automatically add paragraphs box ticked

(Automatically add paragraphs option ticked)

***

Step 6 – Refresh the web browser.

After adding the text widget and formatted content, go to the front-end of your site and refresh your web browser. If all links have been entered correctly, then the clickable support button should display at the top of your sidebar menu …

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

(Clickable support button widget on sidebar)

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

Step 7 – Test the button.

The final step is to make sure that the destination link works. Test the button to make sure that your visitors will go to your help page when clicking the graphic image. You should be taken to the support page …

Test your text widget to make sure it works

(Test your text widget)

Practical Tip

Tips:

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

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

To this (i.e. insert the section containing target=”_blank” in your html code):

Add A Clickable Contact Button To Your Sidebar Section Using A Text Widget - open in new window

When inserting images into your sidebar navigation 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 may display different column widths 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 graphic image, 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 section.

Adjust column width or reduce image size

(Adjust column width or reduce image size)

Additional Tips:

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

How To Add And Configure Widgets On The Sidebar

***

This is the end of part 2 of this tutorial series.

Click on this link to continue:

***

"I am beyond impressed with what you have put together. I can tell that you put a ton of hard work into building what you have. You have the absolute best content on WordPress I have ever seen!" - Robert T. Jillie