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 The WebsiteIn Part 1 of this tutorial series, we explained the basics of using WordPress widgets.

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

How To Configure Widgets

By default, your site comes with several built-in active widgets, such as widgets that let you display links to your site’s pages, filter posts by categories, newsfeeds, add a search box, etc.

In a default WordPress installation, your site comes with several pre-installed widgets

(In a default WordPress installation, your site comes with a number of built-in widgets)

How To Set Up Widgets On Your Blog Sidebar Area: Step-By-Step Tutorial

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

  • Adding a Contact Us image linking visitors to the contact page.
  • Adding a Categories section.
  • Add a Recent Posts section.
  • Add a list of your site’s main Pages.
  • Display important Links on the sidebar.
  • Displaying news items using an RSS Feed section.
  • Add a list of clickable tags through a Tag Cloud section.
  • Add and configure an Archives section to the sidebar navigation menu.

To use widgets, access the Widgets section located inside your WP dashboard by going to Appearance > Widgets

Understanding WordPress For Newbies: About WordPress Widgets

(Widgets Menu)

This brings up the Widgets panel into your browser window …

Widgets Panel

(Widgets Screen)

Let’s get started …

Adding Text Widgets To The Blog Sidebar

Text widgets are versatile …

Text widget

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

A text widget lets you insert just about anything you want into the sidebar menu or other widget sections, such as policies, ads, scripts and more to your site … just by typing in text or pasting 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 really useful

(A text widget is very useful!)

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

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

Use A Text Widget To Add A Clickable Help Button To Your Sidebar Navigation Menu

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

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

Step 1 – Upload your image.

Upload the image to the images folder in your server and write down the URL pointing to your image location.

E.g. …

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

You will need this information in Step 3.

In order for someone to go to the contact page when they click on the help 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 – Add a support page.

Create a contact page and note its URL …

Using A Text Widget To Add A Help Button To The Sidebar Navigation Area

Step 3 – Compose the 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. Basically, you just need to create the instructions linking your graphic image to the contact page/helpdesk.

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

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

  • 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 screenshot below shows the sections of the above code that you need to replace with your actual contact page and image URLs …

Use A Text Widget To Add A Clickable Support Button To The Sidebar Navigation Menu

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

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

Next, go back to your Widgets screen …

Activate or deactivate widgets using drag & drop

(Widgets Area)

Step 4 – Add a Text widget.

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

In the Available Widgets area, find a Text widget …

Text widget

(Text widget)

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

Drag-and-drop your Text widget

(Dragging and dropping your Text widget)

Step 5 – Configure your widget settings.

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

Text widget

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

WordPress text widget

Info

Note: Remember to test your contact page and image URLs before pasting scripts into your Text Widget, or your button won’t 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’re typing in formatted content like we’re doing in this tutorial).

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

Automatically add paragraphs option not checked

(Automatically add paragraphs option not checked)

Here is some text with Automatically add paragraphs box ticked …

Automatically add paragraphs option ticked

(Automatically add paragraphs option checked)

***

Step 6 – Refresh the browser.

Once you have added your widget and content, visit the front end of your site and refresh the web browser. If all links have been entered correctly, then your support button should display in your sidebar menu …

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

(Clickable button widget on sidebar)

The above screenshot shows the support contact button added to a brand new WordPress site.

Step 7 – Test your widget.

The final step is to make sure that the destination URL works. Test this by clicking the button. If you are taken to your support page, then your text widget has been set up correctly …

Test your text widget

(Test the text widget)

Useful Tip

Text Widgets – 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 in), then change the button code from this:

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

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

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

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

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

(Adjust column width or reduce image size)

Additional Tips:

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

How To Add And Configure Widgets In WordPress

***

This is the end of section two of this series of tutorials about using WordPress widgets.

Click here to read the rest of this tutorial:

***

"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