J. Cornelius

On administration

Random Password Generator - July 13, 2008 - 11:47:01 AM

Everyone needs a password for something from time to time. It's usually a pain to try to think of something unique and hard to guess. This is a handy tool that creates random character alpha-numeric, case-sensitive passwords on the fly. Here is your password: Want to go again? Just select how many characters you want in the password, and how many passwords you want to... continue »

Updating Random MySQL Data - April 7, 2006 - 09:41:47 AM

Contest winners are supposed to be random, pulled from a hat so to speak. The process of doing that is a little less obvious when that hat is a MySQL database with 500,000 people in it. You can't just stick your hand in and grab the first peice of paper you feel. Wait.... actually you can. So I needed to select a random group of people from this MySQL table. It's super easy to... continue »

Website and MySQL Monitoring - March 15, 2006 - 11:24:38 PM

siteWatcher is an easy way to check if your Websites and MySQL databases are up and running. It runs on a schedule you set and simply checks your websites for content you specify and notifies you by email if that content is not found. You can also use it to check connectivity to MySQL databases. To setup siteWatcher all you need to do is download the PHP file, put it on your server... continue »

Custom 404 pages and Google - March 15, 2006 - 10:57:38 PM

Everyone wants to display friendly error pages for visitors to thier website. This is easy to do using a variety of methods, but are the common methods always the best decision? There are an abundance of pages that discuss how to make custom 404 error pages. While this practice is an excellent way to help direct misguided visitors to the correct area of your website, it can have some... continue »

Bulk Zone File Maker - May 22, 2005 - 01:49:54 AM

If you've ever had to create a bunch of zone files for a bunch of domains you know it can be a pain. Should you ever find yourself in that dark hole again use this. It is a quick and simple DNS Zone File creator for BIND. It takes an array of domain names, creates zone files and adds the zones to your master BIND configuration. All you need to do is put the domains in the array and restart... continue »

Deny Access by User Agent - May 18, 2005 - 11:11:44 PM

The more traffic your Website gets, the more important efficient handling of that traffic becomes. First you want to be sure that your visitors get a fast response, but you also want to make sure that bogus traffic doesn't suck all your bandwidth. Here is a simple way to keep bogus traffic off your Website. Bogus Traffic? O yea... those pesky offline browsers (or site stealers, who... continue »

Check and Restart MySQL with a Cron - August 9, 2004 - 11:05:04 PM

If you have a MySQL powered website it is critical that the MySQL Server is running. This little diddy will check to see that the MySQL Server is running and restart it if it's not.You will need to add an entry to your crontab that runs on a interval you are comfortable with. This example runs every minute although you can set it to run as often as you like. The command is very low on system... continue »

Change MySQL root password - June 5, 2004 - 01:34:51 AM

This is the 'hands-on' way of changing the root password for your MySQL server. Get to a command prompt on the MySQL server and enter the following commands: mysql -u root mysql > UPDATE user SET password=password('secret') WHERE user='root'; > flush privileges; This should reset the password for you and then you can log in and get some real work done. continue »

Apache Server Response Codes - April 17, 2004 - 12:06:53 PM

Even a seasoned developer can forget the standard response codes for the Apache Server. This list will refresh your memory. If you are looking to customize your 404 pages check this out Successful Client Requests: 200 OK 201 Created 202 Accepted 203 Non-Authorative Information 204 No Content 205 Reset Content 206 Partial Content Client Request Redirected:... continue »

Always add WWW to your URLs - February 19, 2004 - 10:50:55 PM

It's always a good idea to have all the traffic for your site go to www.yourdomain.com. Through the magic of Apache mod_rewrite, you can keep your URLs clean and tidy. Often times people will just type your domain name (i.e. "yourdomain.com") into their browser to get to your website. This can cause some interesting and undesired issues, especially if you plan to do any detailed log... continue »

Converting Seconds in PHP - January 14, 2004 - 10:48:51 AM

All of the conversion functions that I found seemed really bloated. Here is a nice clean way to convert seconds to a more user friendly hour:minute:seconds format. This example takes the current Unix time and converts it to the desired format. Of course you can use this for just about any application that requires you to convert seconds to a more readable format. $seconds = time(); $time =... continue »

Change Your Lost Webmin Password - September 12, 2003 - 10:39:43 PM

At some point you will find yourself locked out of your Webmin console and in need to change the password for your user. Here's how:First, SSH/Telnet to the box in question. You will need to know where Webmin is installed and the path to the script we will be using. > whereis webmin should print something like: webmin: /etc/webmin Then enter: > locate... continue »

About

J Cornelius is a software developer, Web developer, and Formula 1 fan in Atlanta GA. He has a strange affinity for odd numbers, european sports cars, thoughtful analogies, and is hopelessly addicted to chips & salsa. Read more

Recent Articles