United States Zip Code Database

June 15th, 2008

Here is a pretty accurate US zip code database in SQL. It has the zip code, city, state abbreviation, longitude and latitude.

GeoCalc 2.1 Problems with Windows XAMPP

May 15th, 2008

If you are receiving output from the GeoCalc.class.php v2.1 file, change the opening PHP tags from <? to <?php

Getting sound working with Diablo II on Linux with Wine

April 14th, 2008

If you’ve installed Diablo II using WINE and you have no sound, first verify that you have sound otherwise.

Next open the Wine regedit tool (Registry Editor … in GNOME you use Applications -> Wine -> regedit)

Browse to HKCU (HKEY_CURRENT_USER)/Software/Wine

If you see the key (folder) Alsa Driver, great. If not, create it.

Add a String Value to the Alsa Driver key (folder) called UseDirectHW with a value of y (UseDirectHW=y)

Close regedit.

Fire up Diablo II and enjoy sound.

Quickly writing PHP code with XAMPP in Windows

March 26th, 2008

In a message received on PHPBuilder:

“Hi, I am writing to you because you seem willing to help newbies out. I can’t for the life of me test my scripts. I use xampp and it seems to be running fine. I am able to start Apache and then browse to my local host. I have a file named hello.php. I am not able to view it by entering it at the end of the URL. I think it has to do with where I am saving the file or how I’m calling it or both. I was told to save it in xampp folder htdocs. I tried that with no luck. Do I need to extract xampp to a specific folder? Is there any configuration that must go on once it’s installed? How do I view that page locally so I can test my scripts?

Any info is really appreciated. Thanks in advance.”

My response:

“Here is what I usually do:

Download Apache Friends XAMPP ZIP from http://www.apachefriends.org/downloa…n32-1.6.6a.zip

Extract it to c:\, so now we have c:\xampp

Go into c:\xampp and run setup_xampp.bat

Go into c:\xampp\htdocs and delete everything

Run c:\xampp\xampp_control.exe and start Apache and MySQL

Put your scripts into c:\xampp\htdocs and visit http://localhost/

Hope that helps.”

The conclusion:

“Thank you very much!. That worked and I can now test my scripts. I really appreciate the help.”

Test

March 25th, 2008

This is a test

<?php

  echo ‘Hello World!’;

?>