Categories
Home Brewing

Triple-X Milk Stout Recipe

This recipe has brewed for the 2009 National Teach-A-Friend-To-Brew Day.  I like malt forward beers.  This beer is a big malty beers with lots of mouthfeel and a bit a residual sweetness.  It comes across as having chocolate and coffee notes with some caramel.  The fermentation leaves some fruit notes like plum.  Not much head retention at this point, but that may change as the beer conditions. This recipe is from Brewing Classic Styles by Zamil Zainasheff & John Palmer.

Categories
Home Brewing

Brew System Envy

My friend, Andy, recently ordered a brewing system from Sabco.  He has the Brew Magic system.  I don’t brew anywhere near enough to justify such a setup, but that doesn’t mean that I am not jealous.

It has all of the computer-gee-wizardry that a home brewer could dream of, plus plenty of shiny stainless steel. Would it really make better beer than my Igloo coolers and Little Giant Ladder setup? I don’t think so, but it still would be cool.

Categories
Programming

USPS PHP Class

The shopping cart that I wrote some time ago has used rate and zone tables that were loaded into the local database.  The USPS rate and zones have been harder to get in CSV (comma separated variable) format for the last couple of years.  It was now time to drop the local rate charts and use the USPS online tools.

The USPS tools are nice in that they use XML to format both the request and the results. You format a request with your USPS User ID, the originating ZIP code, the destination ZIP code and the package weight and the tool returns a list of the available services and rates. This is nice, except that my old shopping cart expects to make a rate lookup for each service that it supports. I didn’t want to overload the USPS online tool. This class will cache the results of a rate request for a ZIP code and weight combination.  Create an instance of this class early in your PHP module. I used the object as a global data structure. At the point were I needed to do the rate lookup, it was easy to access the data.

$rate = $usps->GetRateUS_byService($dest_zip, $weight, 'Parcel Post');
$rate = $usps->GetRateUS_byService($dest_zip, $weight, 'Priority Mail');

If anyone has any improvements I would be interested in seeing them.

uspsTools.tar.gz