Site Technology

WordPress

This site uses WordPress. If you don’t know, WordPress is free, and very popular, blogging software. It can also be used as a Content Management System (CMS). What is a CMS? Basically, it’s a very easy way to build and maintain your website. Once the CMS is installed, you can easily add new pages, change pages, delete pages, etc. Working on your site becomes fun, rather than a chore.

I like WordPress because it is a great program. I also like the fact that it is written in PHP, which makes it very easy to modify if you are a programmer. The main drawback to using any CMS is that they are an additional layer of software, and noticeably slow down your site, as compared to using plain HTML. With plain WordPress, you might see this page take 3 seconds to load. If it were plain HTML, it would be at least twice as fast. But the fix is easy, and brings us to another great aspect of WordPress: lots of free plugins.

WordPress Theme Customization

I am still using the default WordPress theme. I intend to make my own theme in the future, so I am not going to spend time picking another one right now. It’s pretty easy to change themes, but it is a good idea to keep a list of any customization you may have done. For example, if I were to switch themes now, the copyright notices that appear at the bottom of each page would disappear. Then I would have to go back to the footer.php file and type the copyright notice back in.

Social Bookmarks

If you look down at the bottom of this page, you will see icons put there by this plugin. You can click one of the icons to have a bookmark of this page sent to your social network. This is a good way to spread the word about your blog. Actually, your readers will be spreading the word, but you have to put the icons there for them to click. The plugin is very cool and has many more icons than the ones I use. There are quite a few social networks these days, but I only use the icons for the most popular ones. The plugin makes it very easy to select which ones you want to show up. As of this writing, Stumble Upon seems to be the most popular network for people who talk about blogs and websites. If you get “stumbled”, you could have a very large number of people showing up on your site very quickly.

WP-Cache

WP-Cache is a free plugin that will make your WordPress site run faster. Normally, WordPress would pull your words out of the MySQL database and construct the HTML that is then sent to the browser. That’s a lot of hoops to jump through. What WP-Cache does is save a copy of that HTML, and the next time the page is requested, the saved copy is sent, which is very quick. (There are other caching options available for super high-traffic sites.) WP-Cache requires that you have another plugin installed:

Exec-PHP

Exec-PHP is a free plugin that lets you embed PHP code in your WordPress posts and pages, sort-of like the way you can put JavaScript code into HTML pages. You need this to run WP-Cache, and you may find further use for it at some point in the future when you need a little bit of customization.

Google Analytics

I like to use Google Analytics to study my web traffic. It’s free, and a very nice program. With HTML pages, you have to paste the Google Analytics code-snippet onto each page, which can be a huge job on a large site. With WordPress, all you need to do is slap in this plugin. (Note: the name of this plugin is “Google Analytics”, which is not a good idea, and probably not even legal, but Google doesn’t seem to care. The two links above are different though, so make sure to click each.)

WordPress Notes

When you go to the WordPress installation page, you will see the “Famous 5-Minute Install” section. Don’t believe it. I have installed WordPress several times, and it was always a major hassle. I have a degree in computer science and decades of professional experience, and if it’s not easy for me, its not easy for hardly anybody.

When I installed WordPress on this site, I almost made it through all the flaming hoops, but the last one got me. My hosting company appears to have their MySQL databases running off of a separate server, so the default setting didn’t work. If this happens to you, see if you can use your website’s control panel to log into phpMyAdmin - the server address shown their is probably the right one.

Of course, WordPress is server-side software and usually handled by rocket scientists, so perhaps it was not deemed necessary to include informative error messages to help users solve problems during the install process. But that’s what WordPress needs. Sometimes it will give you no message at all - just a blank page! The only thing you can do with that is look into the source code to try and get an idea of what went wrong, which is clearly far beyond the capabilities of not only the average person, but of the average programmer. Not good. But don’t worry too much; the rest of WordPress is fantastically user-friendly.

Plugin Notes

Uploading - When uploading plugins, your FTP program may ask you if you want to upload a file in text-mode or binary-mode. It does that because it doesn’t recognize the file extension, or because there is no file extension. Normally, binary-mode is the right answer, but if something goes wrong, this could be the cause of the problem. It is possible for a text configuration file to get messed up because binary-mode won’t adjust the end-of-line characters, but I have never seen it happen yet. Just something to keep in mind…

Updating - It is a good idea to visit your Plugins page in your WordPress admin panel periodically. WordPress will alert you when there is a new version of itself available, but not plugins. It will, however, show a message on the Plugins page. Each plugin is a potential securitiy problem. If a plugin has a flaw that can be exploited, you want to be sure to installed the fixed version as soon as possible.

Security - It is not a good idea to mention the plugins that you are using on your site, or that you are even using WordPress. If a hacker knows what software is running on your server, it is much easier for him to design an attack. I have listed my plugins here because this is not a mission-critical site, I watch it daily, and can fix any problem that might arise quickly.

Reliability - The fact that most WordPress plugins are free isn’t always such a good thing. Often, the programmer will lose interest in his plugin because he is not making any money from it. He has to spend most of his time and energy doing something else to make a living, and updating his once-beloved plugin turns into a thankless chore. Each new WordPress update breaks many plugins, and not all of them get fixed. So, before you upgrade to a new version of WordPress, you should visit the home page of each one of your plugins and see if each will continue to work.

Rejected Plugins

Amazon’s Context Links Widget

This widget is a good idea, but as of March 2008, I didn’t like the way it worked.

(If your site gets a good amount of traffic, you can make a few extra bucks by joining Amazon’s Associates program. When you mention something that Amazon sells, which is just about everything, you make a link to Amazon, and will get a commission if your reader goes there and buys something. You can see an example of an Amazon link in the last paragraph of this page.)

Making Amazon links takes time, and the Context Links widget will help you out by automatically reading your pages and inserting links. This is a great time-saver, but only if you don’t mind looking dumb because this widget will make a lot of dumb links. For example, to test the widget, I typed “Harry Potter” onto one of my pages. Did the widget automatically make a link to one of the enormously popular books or movies? Nope. It made a link to a weird Harry Potter doll, that ranked very low in Amazon’s sales statistics. And that wasn’t even the most egregious example.

This widget is not a plugin, but is easy to install anyway. Once you get the code snippet from Amazon that contains your account-ID, you just paste it into your footer.php file. You do that in the Theme Editor section of your WordPress admin panel. Just paste the code above the </body> tag.

After you install the widget, nothing will happen. For some reason, Amazon’s system takes a while to actually start working. Check it the next day, and you will probably see the links. If you are using an advertising-blocking plugin in your web browser, you probably won’t see the links, so you might have to edit the filters and remove the one for Amazon.

Custom Plugin: Withholding Taxes Chart

I wrote a custom plugin for my Withholding Taxes Chart page. The plugin creates a control panel for me in WordPress’s admin area where I enter the new number each business day. The plugin also creates and processes the spot-check form on the page, and shows the “updated date” at the top of the page using custom functions called with embedded PHP code. The plugin also makes the three charts at the top of the page. It pulls the data out of the database, sends it to the browser, then the browser sends it to the Google Chart API, and Google sends back the chart to your browser.

Leave a Reply