Author Results

Developer’s Toolbox: phpMyAdmin

Thursday, December 27th, 2007

In this second installment of the Developer’s Toolbox, I’ll be sharing with you another of my favorite tools that saves me a lot of time and energy: phpMyAdmin. As comfortable as I am doing things from the command line, there are certain tasks in MySQL that are quite tedious to do by hand. Having a user interface to use makes these tasks much easier and quicker to complete.

If MySQL is not your DB of choice, there are other applications out there for interfacing the various other database platforms (such as phpMyAdmin’s relative for PostgreSQL, phpPgAdmin), but MySQL is the most widely used and phpMyAdmin is often included or offered as a part of many basic hosting plans.

As of this writing, 2.11.3 is the most current version of phpMyAdmin. It can be downloaded at the main phpMyAdmin download page. Please follow the installation instructions found in the phpMyAdmin documentation. I’m going to show you how to use phpMyAdmin to create a new database, create tables, insert records, backup your data, and import data into your database. There are many, many other things you can do with this wonderful application, but I’ll keep it simple.

(more…)

Five Horrific Things You Can Do To Kill Off Your Community

Wednesday, October 31st, 2007

Running a community site can be absolute murder sometimes. Keeping the balance between a happy operator and happy users is a deadly dance. Being the owner/operator of a now comatose niche community site has given me the supernatural power to see into the future and warn you about the baleful consequences of ignoring the blood-thirsty mob. Here are five grisly mistakes you can make when running a community site, be it a blog, social network, or message board:

(more…)

Developer’s Toolbox: Web Developer Firefox Extension

Wednesday, September 26th, 2007

This is the first article in a new monthly series entitled the “Developer’s Toolbox”. Each month we’ll introduce you to a new application or set of tools or plugin or some type of gizmo that will make your life as a developer a little easier.

First up in this series is a tool that I find indispensable and use almost daily: the Web Developer Firefox extension.

(more…)

An Introduction to memcached

Tuesday, July 24th, 2007

“Caching” is a term you’ve probably heard mentioned before in various places (including this site). The idea behind caching is to store a copy of some piece of data so you can re-use it again later without jumping through whatever hoops you had to go through the first time to get it. There are different ways you can cache data (queries, objects, etc) and different medium in which you can store the cache (files, database, memory). Any way you do it, the main goal of caching is to increase the performance of your site or application. In many cases caching is used to lessen the amount of interaction with the database, which increases performance and decreases the load on your server.

I would like to talk about my personal favorite method of caching: memcached. I’ll show you how memcached works, how to install it, and how to use it to help your site/application run faster and scale better. According to the memcached site, “memcached is a high-performance, distributed memory object caching system, generic in nature, but intended for use in speeding up dynamic web applications by alleviating database load.” In plain English, this means memcached is an application that you can use to take advantage of spare free memory on any number of machines to cache pretty much anything you want (with a few exceptions) and retrieve it very quickly. Memcached was originally developed by Danga Interactive to help speed up LiveJournal. Some of memcached’s great features are that in runs on a number of platforms (Linux, BSD, Windows), is VERY fast, and has a number of client APIs already written so you’ll more than likely find libraries for any type of project you’re working on. We’ll focus on the PHP API in this article.

(more…)

The Lazy Programmer – Open Source and You

Thursday, June 21st, 2007

Larry Wall (of Perl fame) once wrote in the “Camel Book” that the three virtues of a great programmer are laziness, impatience, and hubris. Out of these three, laziness is my favorite. Wall defines this as “The quality that makes you go to great effort to reduce overall energy expenditure. It makes you write labor-saving programs that other people will find useful, and document what you wrote so you don’t have to answer so many questions about it. Hence, the first great virtue of a programmer.”

He goes on to talk about coding and documenting in such a way so as to not create more work for yourself down the road, but he never addresses how to make the initial effort easier. I want to give a few pointers as to how you might get off on a good start.

(more…)

Simple Tips to Help Survive The Digg Effect

Wednesday, May 30th, 2007

You’ve just posted a killer blog entry and submitted the link to digg. You get a hundred or so diggs in the first hour, and the next thing you know, you’re on the front page. A couple hundred diggs later, you get one of the various dreaded messages that your site is either dead or dying (“Server cannot be reached”, “Service Temporarily Unavailable”, or the unthinkable “Account Suspended!”).

“How could I have prevented this?”, you ask yourself.

There have been many articles on this topic offering various suggestions such as toying with the webserver and database settings, using a form of query/content caching, and ensuring you use good hosting. All are good suggestions, but what if you’re using a blogging service or shared hosting? The following list contains some very simple ways to help alleviate some of the issues caused by the digg effect.

  1. Monitor the number of diggs: It’s not as if you wouldn’t do this anyway, but keeping an eye on the number of diggs and if/when you get front paged helps you get a jump on the traffic spike.
  2. Talk to your hosting provider: Giving your hosting company a heads-up on what’s going on can save them some headaches (especially if you’re on shared hosting) and possibly save you some $$ on your hosting bill.
  3. Turn off comments, widgets, etc: Most diggers don’t comment on dugg pages anyway, so one less trip to the database can make a big difference. Have a rating widget you can disable? Do it. Try to keep the number of queries to the database to a minimum.
  4. Don’t use images or other media: Content is king, right? Unless you’re specifically posting an image or some other media, don’t include additional images or media. Each one is another request that the server has to handle and another chunk out of your bandwidth cap.
  5. Post a static copy: Some blogging tools will create a static copy of your post. A static page uses much less server resources to serve than a dynamic one. If you don’t have that option, create a static copy and redirect to it. If things are still slow, post a “print friendly” text only version that removes all the excess chrome from your site.
  6. Redirect to a copy on a caching service There are a couple of caching services that are great for situations like this: DuggMirror and CoralCache. They’ll cache a copy of your page and have the infrastructure to handle very high loads. It’s a good idea to follow their instructions and populate a cached copy as soon as you submit to digg. With the more popular stories, diggers will refer to the cached copy when the dugg page gets slow, but often the cached copy is too late and grabs a copy of one of the dreaded “dead site” messages. Better yet, why not create a cached version using CoralCache and submit the link to the cached version to digg.

I can’t guarantee that doing all these things will keep your site from faltering to the almighty digg, but they’ll certainly help keep it alive as long as possible. Happy digging!

Jeremy Ashcraft has been working with this ‘internet thing’ since 1997 and has a great affinity for Linux, PHP, beer, metal (the musical kind), and pole vaulting, but not necessarily in that order.
mulberry sale spyder womens jacket cheap new balance 574 mulberry outlet cheap new balance 574 arcteryx outlet mulberry sale spyder womens jacket mulberry sale spyder womens jacket mulberry outlet mulberry outlet new balance 574

Popular Articles

Top 10 Commentators


Subscribe to this feed! Subscribe by Email!

Random Bits Podcast

You need to download the Flash player from Adobe

Other Sites