Chapter 10
In This Chapter
Plugging in to plugins
Finding, downloading, and unpacking plugin files
Using the plugins that come with WordPress
Uploading and installing plugins
Activating and managing plugins
Uninstalling plugins
Exploring open source plugins
Half the fun of running a WordPress-powered blog is playing with the hundreds of plugins that you can install to extend your blog’s functions and options. WordPress plugins are like those really cool custom rims you put on your car: Although they don’t come with the car, they’re awesome accessories that make your car better than all the rest.
By itself, WordPress is a very powerful program for web publishing, but by customizing WordPress with plugins — add-on programs that give WordPress almost limitless ways to handle web content — you can make it even more powerful. You can choose any plugins you need to expand your online possibilities. Plugins can turn your WordPress installation into a full-featured gallery for posting images on the web, an online store to sell your products, a user forum, or a social networking site. WordPress plugins can be simple, adding (say) a few minor features to your blog, or they can be complex enough to change your entire WordPress site’s functionality.
In this chapter, you find out what plugins are, how to find and install them, and how they enhance your blog to make it unique. Using plugins can also greatly improve your readers’ experiences by providing them various tools to interact and participate — just the way you want them to!
In this chapter, I assume that you already have WordPress installed on your web server. Installing plugins pertains only to the WordPress.org software. If you’re skipping around in the book and haven’t yet installed WordPress on your web server, you can find instructions in Chapter 6.
A plugin is a small program that, when added to WordPress, interacts with the software to provide some extensibility to the software. Plugins aren’t part of the core software, nor are they software programs themselves. They typically don’t function as standalone software. They do require the host program (WordPress, in this case) to function.
Plugin developers are the people who write these gems and share them with the rest of us — usually for free. As is WordPress, most plugins are free to anyone who wants to further tailor and customize a site to meet specific needs.
Literally thousands of plugins are available for WordPress — certainly way too many for me to list in this chapter alone. I could, but then you’d need heavy machinery to lift this book off the shelf! So here are just a few examples of things that plugins let you add to your WordPress blog:
Chapter 14 gives you a peek at some of the most popular plugins on the scene today. In the meantime, this chapter takes you through the process of finding plugins, installing them in your WordPress blog, and managing and troubleshooting them.
Before you start installing plugins for your blog, it’s important for you to explore the Plugins page on your WordPress Dashboard and understand how to manage the plugins after you install them. Click the Installed Plugins link in the Plugins menu on your WordPress Dashboard to view the Plugins page shown in Figure 10-1.
The Plugins page is where you manage all the plugins you install in your WordPress blog. By default, the Plugins page displays a full listing of all the WordPress plugins you currently have installed. You can filter the listing of plugins using the links shown directly below the Plugins page title:
wp-content
directory that modify the core settings of WordPress (mostly having to do with caching or other server-specific settings). These files don’t show up in the main plugin listing because they typically belong to other plugins. The Drop-Ins link appears only if you have drop-in plugins installed.With a quick glance at the Plugins page, you can easily tell which plugins are active — and which aren’t — by the background color of each plugin listed. A blue background means that the plugin is not active. A white background means that the plugin is active. In Figure 10-1, the background of the Akismet plugin is gray and the background of the Hello Dolly plugin is white. Akismet isn’t active, but Hello Dolly is.
The Plugins page displays plugins in two columns, which give details for each plugin:
Sometimes, a plugin will have a separate settings page; in that case, an additional link labeled Settings is displayed underneath the plugin name. Clicking that link takes you to the settings page for that plugin.
For a lot of reasons, mainly security reasons and feature updates, always use the most up-to-date versions of the plugins in your blog. With everything you have to do every day, how can you possibly keep up with knowing whether the plugins you’re using have been updated?
You don’t have to. WordPress does it for you.
Figure 10-2 Shows an out-of-date version (2.5.7) of Akismet installed. WordPress notifies you when a new update is available for a plugin in four different ways, as shown in Figure 10-2:
There is a new version of Akismet available. View version 2.5.9 details or update now
.WordPress gives you not only a message that a new version of the plugin is available, but also a link to a page where you can download the new version, or a link that you can click to update the plugin right there and then — WordPress’s one-click plugin update.
Click the Update Now link, and WordPress grabs the new files off the WordPress.org server, uploads them to your plugins directory, deletes the old plugin, and activates the new one. (If a plugin is deactivated at the time it’s updated, WordPress gives you the option to activate the plugin after your update process is completed.) Figure 10-3 shows the Update Plugin page that you see while the plugin is being upgraded.
Figure 10-4 shows my Dashboard telling me that I have one plugin that needs to be upgraded. After you upgrade the plugin, the number disappears.
At this writing, WordPress packages two plugins with the installation files:
I touch on Akismet a few times throughout this book. It’s my humble opinion that Akismet is the mother of all plugins and that no WordPress blog is complete without a fully activated version. Apparently WordPress agrees, because the plugin has been packaged in every WordPress software release since version 2.0. Akismet was created by the folks at Automattic — the same folks who bring you the Sidebar Widgets plugin. Akismet is the answer to comment and trackback spam.
Matt Mullenweg of Automattic says that Akismet is a “collaborative effort to make comment and trackback spam a non-issue and restore innocence to blogging, so you never have to worry about spam again” (from the Akismet website at http://akismet.com ).
To use the plugin, follow these steps:
A box appears at the top of the page, saying: Activate your Akismet account. Almost done – activate your account and say goodbye to comment spam.
(See Figure 10-5.)
Clicking this link takes you to the Akismet page in your WordPress Dashboard, where you can create an Akismet key, required in order to use the Akismet plugin.
This opens the Akismet website in your browser window at http://akismet.com/wordpress.
This opens the signup page on the Akismet website. Because Akismet is hooked into the WordPress.com service, if you already have a WordPress.com account, click the I Already Have a WordPress.com Account link; otherwise, fill in the text fields and provide your e-mail address, desired username, and password to create one.
After you have done this, Akismet requests that you authorize your account with Akismet — click OK.
After you’ve gone through the signup process, Akismet provides you with an API key. Copy that key by selecting it with your mouse pointer, right-clicking, and selecting Copy.
On the Akismet configuration page, after you’ve entered and saved your key, you also have two options that you can select to further manage your spam protection:
Akismet catches spam and throws it into a queue, holding the spam for 15 days and then deleting it from your database. It’s probably worth your while to check the Akismet Spam page once a week to make sure that the plugin hasn’t captured any legitimate comments or trackbacks.
You can rescue those nonspam-captured comments and trackbacks by doing the following (after you’ve logged on to your WordPress Dashboard):
The Comments page appears, displaying a list of the most recent comments on your blog.
The Comments page now displays all spam comments that the plugin caught.
The comment is marked as legitimate. In other words, you don’t consider this comment to be spam. The comment is then approved and published on your blog.
The folks at Automattic did a fine thing with Akismet. Since the emergence of Akismet, I’ve barely had to think about comment or trackback spam, except for the few times a month I check my Akismet spam queue.
Matt Mullenweg, co-founder of WordPress, developed the Hello Dolly plugin. Anyone who follows the development of WordPress knows that Matt is a huge jazz fan. How do we know this? Every single release of WordPress is named after some jazz great. One of the most recent releases of the software, for example, is named Parker, after jazz great Charles Parker; another release was named Coltrane, after the late American jazz saxophonist and composer John Coltrane.
So, knowing this, it isn’t surprising that Mullenweg developed a plugin named Hello Dolly. Here’s the description of it that you see in the Plugins page on your Dashboard:
This is not just a plugin, it symbolizes the hope and enthusiasm of an entire generation summed up in two words sung most famously by Louis Armstrong: “Hello, Dolly.” When activated, you will randomly see a lyric from “Hello, Dolly” in the upper right of your admin screen on every page.
Is it necessary? No. Is it fun? Sure!
Activate the Hello Dolly plugin on the Plugins page on your WordPress Dashboard. When you’ve activated it, your WordPress blog greets you with a different lyric from the song “Hello, Dolly!” each time.
If you want to change the lyrics in this plugin, you can edit them by clicking the Edit link to the right of the Hello Dolly plugin on the Plugins page. The Plugin Editor opens and lets you edit the file in a text editor. Make sure that each line of the lyric has its own line in the plugin file. This plugin may not seem very useful to you and, in fact, it may not be useful to the majority of WordPress users, but the real purpose behind the plugin is to provide WordPress plugin developers with a simple example of how to write a plugin.
This book does not cover topics on how to create your own plugin, but if you are interested in that, you may want to check out my other book, WordPress All-in-One For Dummies (John Wiley & Sons, Inc.), which covers that topic in detail.
In this section, I show you how to install a plugin in your WordPress blog using the built-in plugins feature. The auto-installation of plugins from within your WordPress Dashboard works only for plugins that are included in the official WordPress Plugin Directory (http://wordpress.org/plugins). You can manually install plugins on your WordPress blog, a process that I cover in the next section.
WordPress makes it super easy to find, install, and then activate plugins for use on your blog. Just follow these simple steps:
The Install Plugins page opens, and you can browse the official WordPress Plugins Directory from your WordPress Dashboard.
Enter a keyword for a plugin you’d like to search for. For example, if you want to search for plugins that allow you to add additional features for comments on your site, enter the word Comments in the Search Plugins text box to return a list of plugins that deal specifically with comments.
You can also search by tag by clicking any of the tag names that appear at the bottom of the Install Plugins page under the Popular heading.
I want to install a very popular plugin called Subscribe to Comments, by Mark Jaquith (see the following section, “Installing Plugins Manually,” for a description of this plugin). To find it, enter the words Subscribe to Comments in the Search text box on the Install Plugins page. Then click Search Plugins.
Figure 10-7 shows the results page for the Subscribe to Comments search phrase, which is listed as the first plugin on the Search Results page.
A Description window opens, giving you information about the Subscribe to Comments plugin, including a description of the plugin, version number, author name, and an Install Now button.
You go to the Installing Plugins page within your WordPress Dashboard, where you find a confirmation message that the plugin has been downloaded, unpacked, and successfully installed.
Two links are shown below the confirmation message:
In the following sections, I show you how to find, upload, and install the very popular Subscribe to Comments plugin, developed by Mark Jaquith. I’m using the Subscribe to Comments plugin as a real-world example to take you through the mechanics involved in downloading, unpacking, uploading, activating, and using a plugin in WordPress.
Subscribe to Comments gives your readers the opportunity to subscribe to individual comment threads on your site so that they receive a notification, via e-mail, when a new comment has been left on the comment thread (or blog post) that they have subscribed to. This plugin helps keep lively discussions active in your blog.
The first step in using plugins is locating the one you want to install. The absolute best place to find WordPress plugins is the official WordPress Plugins Directory found at http://wordpress.org/plugins where, at the time of this writing, you will find over 21,000 plugins available for download.
To find Mark Jaquith’s Subscribe to Comments plugin, follow these steps:
The Subscribe to Comments page opens in the WordPress Plugin Directory, where you find a description of the plugin as well as other information about the plugin (see Figure 10-9). For example, in Figure 10-9, take note of the important information on the right side of the page:
If you’re using Internet Explorer, click the Download button, and a dialog box opens, asking whether you want to open or save the file. Click Save to save the zip file to your hard drive, and remember where you saved it.
If you’re using Mozilla Firefox, click the Download button, and a dialog box opens, asking what Firefox should do with the file. Select the Save File radio button and then click OK to save it to your hard drive. Again, remember where you saved it.
For other browsers, follow the download instructions in the corresponding dialog box.
If you’re unsure how to use your decompression program, refer to the documentation available with the program.
Frequently, the plugin developer includes a readme
file inside the zip file. Do what the title of the file says: Read it. Often, it contains the exact documentation and instructions that you will find on the plugin developer’s page.
Make sure that you read the instructions carefully and follow them correctly. Ninety-nine percent of WordPress plugins have great documentation and instructions from the plugin developer. If you don’t follow the instructions correctly, the best scenario is that the plugin just doesn’t work on your blog. At worst, the plugin creates all sorts of ugly errors, requiring you to start the plugin installation over from step one.
In the case of Mark Jaquith’s Subscribe to Comments plugin, the readme.txt
file contains instructions on how to upload and use the plugin, as well as some answers to frequently asked questions on troubleshooting the installation and use.
Now you’re ready to upload the plugin files to your web server. In earlier versions of WordPress, you needed to upload the unpacked plugin files to your web server via FTP (see Chapter 6). Now, all you need to do is upload the zip file you just downloaded from the WordPress Plugin Directory. Be sure you are logged on to your WordPress Dashboard.
Although, unpacking the zip file you’ve downloaded is helpful because it can contain files that give you insight into the use of the plugin itself. Locate the plugin files you just unpacked on your hard drive. In the event that the plugin developer didn’t include a readme.txt
file with instructions, check the plugin developer’s page for specific instructions on how to install the plugin in your WordPress blog. Specifically, the documentation in the readme.txt
file and/or on the plugin’s website should address the following points:
To install the Subscribe to Comments plugin via the WordPress Dashboard, follow these easy steps:
This opens the Install Plugins page on your Dashboard.
The resulting page gives you an interface for uploading a plugin in zip format.
In the resulting File Upload dialog box, you can locate the zip file for the plugin you’d like to install. In this case, the file is subscribe-to-comments.2.1.2.zip
(see Figure 10-10). Click the file to select it and then click the Open button to return to the Install Plugins page.
WordPress uploads the plugin’s zip file into the /wp-content/plugins/
folder on your web server, unpacks it, and installs it. Figure 10-11 shows the Installing Plugin page with messages for you during and after the (hopefully successful) installation.
All plugins listed on the Plugins page are either active or inactive (except the Drop-In plugins, which are active by default). When you want to activate an inactive plugin, follow these easy steps (in this case, you are activating the Subscribe to Comments plugin that you installed in the previous section):
The Plugins page opens, listing all the plugins installed in your WordPress blog.
If you have a lot of plugins installed on your WordPress website, you can narrow your search by clicking the Inactive link, which lists the currently inactive plugins.
The Plugins page refreshes, and the Subscribe to Comments plugin now appears as an active plugin on the page.
If you’ve followed all these steps in your own blog, congratulations — you now have Subscribe to Comments installed. Great job!
Some, but not all, WordPress plugins provide an administration page where you can set options that are specific to that particular plugin. You may find the plugin administration page in any of these places:
You can find the Subscribe to Comments Options page by clicking the Subscribe to Comments link in the Settings menu. The Subscribe to Comments Options page opens (see Figure 10-12).
After all this talk about installing and activating plugins, what happens if you install and activate a plugin and then at some point decide that it just isn’t what you want? Don’t worry — you aren’t stuck forever with a plugin that you don’t want. WordPress lets you be fickle and finicky in your plugin choices!
To uninstall a plugin from your WordPress blog, follow these steps:
The Plugins page opens.
The Plugins page refreshes, and the plugin now appears as deactivated (or inactive).
The Delete Plugin page opens, and a confirmation message displays asking you whether you’re sure you want to delete this plugin. (See Figure 10-13.)
The Plugins page refreshes, and the plugin you just deleted is gone from the lists of plugins, with a message displayed at the top confirming the deletion of the plugin.
Bang! You’re done. That’s all it takes.
The WordPress software was built on an existing platform called b2. Matt Mullenweg, co-founder of WordPress, was using b2 as a blogging platform at the time the developer of that program abandoned it. What did this mean for its users? It meant no more development unless someone somewhere picked up the ball and continued with the platform. Enter Mullenweg and WordPress.
Apply this same concept to plugin development, and you’ll understand that plugins sometimes fall by the wayside and drop off the face of the earth. Unless someone takes over when the original developer loses interest, future development of that plugin ceases. It’s important to understand that most plugins are developed in an open source environment, which means a few things for you, the end user:
I don’t want to make the world of WordPress plugins sound like gloom and doom, but I do think it’s very important for you to understand the dynamics in play. Consider this section to be food for thought.
18.225.95.107