Wednesday, April 27. 2005Local Wildlife
My wife spotted a snake by the lake while walking the dogs this morning, and I went down to photograph it. It was perched in some brush overhanging the water. At first I thought it was a cottonmouth because it was dark colored and had a thick head that looked triangular. Once I got a few photos, I noticed that the eye was perfectly round, and the snake turned out to be the non-venomous brown water snake, which I've seen before on kayak trips. It was a complacent subject, content to bask in the sun while I walked and waded around its area, looking for the best angle.
On the way back to the house, I spotted a chipping sparrow on the street, apparently eating some of our newly placed grass seed. Paddle Sparkleberry with the Governor![]() South Carolina's governor, Mark Sanford, is going to paddle the Sparkleberry Swamp this weekend. This area is the proposed site of a controversial bridge which will connect the tiny towns of Lone Star and Rimini. The trip is open to anyone who wants to join in. I can't go on the trip, but I agree with the governor that the Sparkleberry Swamp is a poor place to put a bridge. I've paddled this beautiful area twice, in December 2001 and January 2003. The Palmetto Paddlers go there frequently. Sunday, April 17. 2005Bug Mapping
(the insect kind, not the computer kind)
I've always been interested in maps and I've had at least a couple on my walls since I was a kid. That interest has carried over to the computer world, as you can see by the many GPS track maps I publish with my trip reports. I've been a regular participant on the BugGuide.Net website for the past year or so, and I always thought it would be cool to plot a map of the locations where people have photographed their bugs. I offered to give it a try, and Troy Bartlett, the site owner, graciously provided me with the location data to play with. The first hurdle was the free form location data. A photographer could put any location they wanted in that field, and the contents varied significantly. Some would give full state names, others would use abbreviations. Add in several misspellings, some non-U.S./Canada locations and it was hard to work with. (Troy has since modified the website to require users to select from a pre-defined state/province list). I ended up writing a PHP function to try to take a location name and pull the state or province out of it. I basically assigned each state/province an array of possible matches. So West Virginia, for example, was comprised of WV, W. Va., W. Virginia and West Virginia. This worked fairly well. Then it was a matter of arranging the location comparisons so that you get the right state, i.e. you have to check for West Virginia before Virginia because they share names. Through testing I found you also have to put Delaware and Louisiana toward the end of the checks because "de" and "la" appear in some Spanish-based place names. For similar reasons, you need to check Indiana and Ontario toward the end. I found later that it's also a good idea to put Colorado down there since "Co." is an abbreviation for "county." (Click here to see the code). Once I had the locations simplified, I needed a way to plot them on a map. I tossed around various ideas but settled on a good open-source mapping package called MapServer, which I had played around with over the years but never created any applications. I had some publicly available map data "shapefiles" to use, and all I had to do was feed my list of states and provinces to the map template. MapServer did the rest, generating North American maps with the relevant areas colored in. MapServer has lots of features for browsing maps interactively on websites, but for the time I just wanted to create static maps. After lots of testing, I decided it was ready to use. I packaged it up and sent it to Troy, who quickly integrated it into BugGuide as the "Data" page. He adjusted the color scheme and added a neat breakdown of locations by month. While the maps generated aren't comprehensive range-maps, they do show what’s been captured by the website's users, and perhaps with time will approach the true ranges of many species. It's a fun way to use maps on the Internet. Here are a couple examples:
And you can browse the maps anywhere between the phylum and the species...check it out! Sunday, April 10. 2005Suwannee River Trip
I finally finished my writeup, photo gallery, and maps from last month's multi-day paddling trip on the Suwannee River in south Georgia and north Florida. We paddled 70+ miles of river and made a couple interesting side trips before heading home.
Click here to check it out! Tuesday, April 5. 2005The Pollen is a Fallin'
Well, it's early April. Here in South Carolina, the temperatures are in the wonderful 70s (~23°C). Perfect time to open your windows and let in the Spring breezes, right? Wrong.
This also happens to be the time of year the our many loblolly pine trees spread their pollen. Right now the pollen is so thick that you can occasionally see faint clouds of it blowing by, and you can definitely taste it when you're outside for a while. If you do leave the windows open (as we did the first year we lived in SC), you'll get a coating of sticky yellow dust on things inside your house. The picture shows our normally dark blue car that was outside...this was less than 48 hours of pollen accumulation. My allergies can't wait for this event to "blow over." Saturday, April 2. 2005PHP Cybercash PECL Extension
One of my clients still uses the ancient Cybercash payment system, now owned by Verisign. Last I checked, Verisign charges you to switch over to their newer payment system. Since they keep Cybercash running, so there's not much incentive to upgrade.
A Cybercash interface was built into PHP 4.2.x but it was removed in PHP 4.3.x. It wasn't completely abandoned as it was moved to the PECL repository. Unfortunately, there is next to no documentation telling you how to install it. From digging around their mailing lists, I came across this helpful bug report. Not only does it have the instructions for how to install the extension, it tells you how to correct a bug which they still haven't fixed in the downloadable Cybercash package. For my future reference, to install a PECL extension, you copy the extension into a subfolder of php-4.3.x/ext. Then run autoconf at the command line. At that point, you continue with configure, making sure to request that the extension be included. And finally, make and make install.
(Page 1 of 1, totaling 6 entries)
|
CategoriesQuicksearchArchivesSyndicate This Blog |