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 Widgets To The WordPress Blog SidebarIn Part 1 of this step-by-step tutorial series, we cover the basics of how to use WordPress widgets.

In this tutorial you are going to learn how to configure several widgets in WordPress.

Configuring Sidebar Widgets

By default, your site comes with a number of preinstalled widgets that can be used out of the box with little to no configuration needed, such as widgets that let you display links to your pages, filter posts by categories, news items, adding tag clouds, etc.

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

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

How To Set Up Frequently-Used Widgets On The WordPress Sidebar Area: Step-By-Step Tutorial

In this step-by-step tutorial series, you will add, configure and reorder s number of widgets, including:

  • Adding a Contact Us image linking visitors to your contact details page.
  • Add a Categories section with a drop down menu.
  • Add a Recent Posts section.
  • Add a list of the site’s Pages.
  • Display Links on your sidebar.
  • Adding an RSS Feed section.
  • Add a Tag Cloud.
  • Adding and configuring an Archives section to the sidebar.

The Widgets section is located inside the WP dashboard by going to Appearance > Widgets

Understanding WordPress For Newbies: About WordPress Widgets

(Widgets Menu)

This loads the Widgets section in your web browser …

Widgets Section

(Widgets Area)

Let’s get started …

Text Widgets

Text widgets are incredibly versatile …

WordPress Text widget

(Text widget)

Useful 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 your sidebar menu or other widget sections, such as notices, social media buttons, messages and more to your site … just by typing in text or adding HTML into the content area. You can also add an optional title in the Title field. Remember to save your settings when done …

Text widgets are versatile

(A text widget is really useful!)

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

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

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

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

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

Step 1 – Upload your image.

To display an image on your site, the button image must be uploaded to your server. Upload the 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.

For visitors to go to the contact page when they click on the support button, you must either create a contact page, or have an existing destination page already set up (e.g. a helpdesk). We will link the button graphic to this URL in Step 3

Step 2 – Add a destination page.

Create a contact page and note its URL …

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

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

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

Your instructions can be typed into a simple text editor and will look something like this …

Use A Text Widget To Add A Clickable Support Button To Your Sidebar Navigation Section

  • 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 with the URL of your image location.

The image below shows which sections of the above code you need to replace with your actual web addresses …

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

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

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

Go back to your Widgets area …

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 your button to display.

In the Available Widgets area, select the Text widget …

WordPress text widget

(Text widget)

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

Drag-and-drop your WordPress text widget

(Drag and drop your Text widget)

Step 5 – Configure the text widget settings.

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

WordPress text widget

Add a title section to the widget if you want (e.g. “Need Help?”, “Get Support”, etc.) and paste the code with the correct URLs into the large text box, then click the save button …

WordPress text widget

Important Info

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

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

If adding text with no formatting tags, 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 pasting in formatted content like we’re doing in this tutorial).

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

Automatically add paragraphs box not selected

(Automatically add paragraphs box not ticked)

Here is some text with Automatically add paragraphs option selected …

Automatically add paragraphs box selected

(Automatically add paragraphs option checked)

***

Step 6 – Refresh the browser.

Once you have added your text widget and formatted content, visit your site and refresh your web browser. If all links have been entered correctly, then your clickable support button will display at the top of the site’s sidebar menu …

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

(Clickable button widget on sidebar)

The screenshot above shows the support contact button in the sidebar of a newly-installed WordPress site.

Step 7 – Test the button.

The final step is to make sure that your clickable button works. Test the button to make sure that visitors will go to the support page when clicking the button. If you are taken directly to your support page, then the text widget has been set up correctly …

Test your clickable button to ensure you've set everything up correctly

(Test your clickable button)

Useful Tip

Useful Tips:

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

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

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

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

When adding images to your sidebar area, make sure that the width of your image does not exceed the width of the sidebar column, especially if you are using a non-responsive WordPress theme. As we’ve previously mentioned, some themes may display elements differently depending on their templates and their layout. Some sidebars may be wider or narrower. If the sidebar of your theme is narrower than the width of your button image, then you may have to either adjust the size of your images, or the width of your sidebar column to make graphics display correctly on your theme.

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

(Adjust column width or reduce image size)

More Tips:

  • If you don’t want to center the image inside your sidebar, delete the <center> and </center> tags from the beginning and end of the code. The image will then be left-aligned.
  • Link your help button to any destination you like (e.g. to an external link, helpdesk, support forum, etc.) and change this anytime by editing the content in your text widget.

How To Add Widgets To The WordPress Blog Sidebar

***

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

To view the rest of this tutorial, click here:

***

"Wow! I never knew there's so much to learn about WordPress! I bought one of the WordPress for Dummies three years ago, such authors need to be on this course!" - Rich Law, Create A Blog Now