Speed up Wordpress by Trimming Your Bloated Database
September 12, 2008
<new>I’m slowly cleaning up old drafts. This is one from 5 months ago before the redesign (and I’ve not reintegrated Google search yet). However, for those wordpress users - it’s a worthwhile read.</new>
I love analytics. No where else on the web can you get lost in the purity of statistics.
However, there’s a dark side to analytics - storage space.
Admittedly, I don’t take good care of this blog. However, when I went to back up my database today it was 950 mb. Yes, that’s correct, the database was nearing a one gig in size! It wasn’t spam, it wasn’t the huge amount of content on the site, it wasn’t hacked - it was wordpress analytics programs storing stats in the database.
While it’s fun to have access to every possible analytic stat, there’s also something to be said about the speed of your blog (not to mention one should be more concerned about actionable data).
Using phpMyAdmin I removed shortstat, slimstat, and counterize II tables from my database which brought it down to a much more reasonable 50mb; which still seemed large to me. So, after some more rummaging around the database, it seems that Search Meter (a nice plug-in that saves all the searches conducted on your blog) was taking up the last unnecessary 20+ mb in the database.
It was a tough decision to actually put an ad back on the blog. But, the best alternate to the wordpress search was to add a Google custom search. I haven’t figured out the correct layout for the search yet as on some browsers part of the search box is obscured which I’m sure is against the Google TOS - but I’ve not figured out an OK looking CSS yet. However, searches on this site will now have some ads from Google on them. However, I can now get search stats in my AdSense reporting. Unfortunately, that’s not integrated with any other analytics programs yet. I’m waiting for the day Google’s CSE is integrated into Google analytics. That seems the next logical step. One of the best places for keyword research is search results on your own site.
So, after removing those plug-ins, I made sure that both Microsoft Analytics (review here) and Google Analytics (and soon IndexTools by Yahoo) are installed in the blog for full stats. (More free stat programs found via SEMMYs.)
When installing these scripts, please put them in the footer tag (or just above the </body> tag) so that your content loads immediately. It’s ok if you don’t track all your visitors because the tracking script didn’t load. It’s not ok to have your content not load because some tracking script is taking too long to load.
The accomplishment? This blog is loading about 70% faster than previously. A leaner database means a faster site.
P.S. Please use absolute URls for your Favicons. If you use relative paths, the icons will not show up on all pages of your blog.
Wordpress Statistic Plugins Comparisons
January 31, 2007
I’m putting together a comparison chart of several wordpress statistic plugins against some other analytics programs to see how they each record visitors, page views, query strings, referrers, etc.
The analytics programs I’m using are:
- Google Analytics
- AWstats
- Webalizer
- Feedburner
- and if i have time, I’ll do some clicktracks log file analysis.
The Wordpress Stat Plugins I’m using are:
- bSuite (which seems to have issues)
- Counterize II
- Short Stats
- Slim Stats
Did I miss any WordPress Stat plugins that should be compared?
Updated to Wordpress 2.1
January 28, 2007
I updated to wordpress 2.1 today, please let me know if you see any blog problems - they’re not intentional.
I’ve found two issues so far:
BSuite plugin stopped passing stats. However, I’ve had problems with that plug-in before - so it could that issue could be related to something else.
I also had to completely rework the links section. It seems the previous link category tags I was using are no longer supported, and I had to rework some of the coding. Although, it seems its also time to update the entire link section as it’s quite outdated.
As soon as I find an easy way to export Windows Live Mail Desktop OPML; then I’ll rework the link section. I’ve become reliant on that reader since Attensa stopped syncing between their web and desktop apps.
Overall, I do like the upgraded 2.1 interface. I stopped using the rich text editor on the previous interface as it had many issues in various browsers and it was quite difficult to switch between the code and editor interface. WP 2.1 fixes that entire issue (my favorite aspect of the 2.1 upgrade).
If you see any problems with the blog not rendering correctly, please let me know the problem and your browser version.
Thank you.
Wordpress Help Files
January 14, 2007
I recently stumbled upon two nice wordpress help sites that deserve to be recognized.
The first is Tamba2.org.uk. This site has a lot of step by step help files for wordpress.
The second at headzoo is a list of all the tags available in wordpress, and separates them into the appropriate sections. Quite useful when editing files and trying to remember the nomenclature of certain tags.
New Random Quotes Plugin for WordPress
December 2, 2006
I collect quotes. I read quotes. I enjoy quotes.
I recently noticed Llorelle was endorsing and explaining a new quotes plug-in, which can be found here.
Instead of using it for the quotes feature, I’ve installed it with random PPC snippets - sort of mantras for the PPC world.
I think it’s a fun idea, and one way to spice up a blog page (and I’m going to watch the reload stats to see how many people just refresh the page to see a new quote).
It could also be used as a low-tech ad server. However, PHPAdsNew might be a better choice if you have some programming skills.
So - is it good? Taking up valuable space? Comments?
[poll=2]
Be Careful of Security Issues when Using Wiki’s and Blogs with Trackbacks
July 24, 2006
When a website automatically posts comments to another site it is called a trackback. Essentially, Blogs and many Wiki’s automatically post comments on a website’s page (when comments are enabled) when one links to that particular page. In most cases, the trackbacks and comments are used to create a discussion around a particular subject. Hence why Wiki’s and Blogs are key to developing an internet community.
However, wiki’s are also often used in development projects, and if you are not careful with the security settings, you can give away your development secrets. Read more
Feedburner Helps Websites Understand Their Content
July 21, 2006
RSS (really simple syndication) has changed the way users and websites utilize the web. Whenever a new technology comes along that changes the way we interact with the web, new companies emerge to assist with the process and introduce even more new technologies that are built upon making these technologies usable. Enter Feedburner.
The next big thing is what makes the current big thing better
Unfortunately, I can’t remember who said that (and it might not be in it’s exact form), but that is essentially what Feedburner is accomplishing.
RSS is a technology which allows publishers to push their content around the web. Instead of relying on email and newsletters to keep consumers updated with news or features, RSS puts consumers in control. Read more
Add a contact form to Wordpress
July 16, 2006
Please, don’t use a simple mailto link on the web. That’s the single easiest way to increase the amount of spam you receive. Instead, use a contact form. Wordpress has some plugins for email. If these don’t work for you, I’ve included other options available. If you don’t use wordpress, please skip below, there are options available to you covered here.
The simplest way to add a contact form to wordpress is to use one of these plugins:
With servers and senders going through more email verification these days, these two plugins may not work on your server. If these two won’t work, the next option is to install wpPHP Mailer. This takes a little bit more work as it uses a sourceforge php code. Don’t be afraid of working with PHP if you’re unfamiliar with it. This is a fairly straightforward plugin to work with. The main advantage of this one is that it let’s you put in your email password and account, so it will work with many servers which require an additional level of security.
However, if that still doesn’t work for you (some servers again have issues with this particular plugin), the next is to move to the cgi-bin. If you don’t have a cgi bin, write your administrator, most servers come with a cgi-bin and cgiemail installed.
If you happen to have formmail.pl, please read this first before thinking that’s the best way to proceed.
The cgi bin is pretty easy to work with. The main issue most people have using cgiemail is they don’t realize it’s actually two different files they’re working with.
- The first is the actual form. This is a straightforward form which is located on an html or php page (and can be added to a wordpress post or static page so that it’s integrated nicely with your blog).
- The second page is a .txt file that tells the cgi emailer what to do. (Note: The page must be in iso or ascii, cgi doesn’t work properly with all text formats. So, when you save this page, just do a ’save as’ and look through your options - ascii is the best choice).
The last issue is that some servers don’t seem to process the cgiemail form properly unless it’s stored in the root folder (no idea why, this shouldn’t be an issue, but it happens).
Here are the top documents around to show you how to create these forms:
- Official cgiemail page
- An MIT page with additional help
- And yet another good university page from a website creation class
Finally, the last way is to use a wysiwyg editor (such as Frontpage) and publish to your website (the server must have frontpage extensions installed). Since this will not have the ‘feel’ of your blog, you’ll want to create this in a few different steps.
- First, create a new page in Frontpage using the Feedback or Contact Form template.
- Second, customize the form for the fields you wish to include
- Next, publish (since this uses Webbots, you’ll have to publish it, not FTP the page) the page to your server
- Fourth, create a static Wordpress page and use an iFrame to include the contact page in your regular wordpress page
- Complete. You will now have a contact page from Frontpage that utilizes your blog’s template
If this is your first time working with a form, it will take a little bit of time (if you’re creating it from scratch) to make sure all the details are perfect. If you have some experience with HTML, you should be done in 30-60 minutes. If you don’t it might take an hour or two. However, your inbox will be happy with the reduction of spam you receive.











