brettbrewer.com

Programming + Design

Home
PERL Creator sounds off on scripting languages (and skewers them)
Written by Brett Brewer   
Thursday, 27 December 2007
I ran across this fantastic article by Larry Wall, the creator of PERL (the coolest scripting language you'll never bother to learn) called "Programming is Hard, Let's go Scripting... " It's a great perspective on the history of scripting languages as seen by Wall, and in it he skewers many modern languages and is somewhat harsh toward my (and most other people's) favorite scripting language, PHP.  I'm actually surprised I still liked the article. If Larry wasn't obviously a genius I probably wouldn't have liked it much, but he definitely makes some great points and has a great writing style to boot.
Last Updated ( Thursday, 27 December 2007 )
Read more...
 
Migrating PHP4 custom session handlers to PHP5
Written by Brett Brewer   
Sunday, 11 November 2007

Are you using PEAR MDB2 or PEAR DB with PHP5 and custom session handlers? I encountered a frustrating little problem today when trying to migrate a PHP4 application I wrote to PHP5. The app uses custom session handlers to save session data to a MySQL database. Unfortunately, after much hair pulling and messing around with using session_write_close() on various pages in my app to force the session data to be saved, I discovered that the problem was with the PEAR MDB2 database class. As part of my application upgrade I switched from using the deprecated PEAR DB class and moved to the PEAR MDB2 class. Unfortunately, in PHP5, the instance of my MDB2 class is destroyed prior to calling the "session_write" function, causing all session data to be lost when doing page redirects. I tried calling session_write_close() as a shutdown function using register_shutdown_function and it appeared to work. Then I did some more searching and discovered that someone else had already recommended this in the comments on the PHP web site. I don't know if this is really the best solution or whether MDB2 or PHP have a bug that needs to be addressed, but registering session_write_close() as a shutdown function appears to be the only solution that works transparently. So, if you are using PEAR MDB2 or PEAR DB and you find that your custom session handlers break when you move from PHP4 to PHP5, you can probably fix it by adding the following line to one of you global configuration files, or, better yet, just add it to whatever include file contains your custom session handlers:

register_shutdown_function('session_write_close');

Hope this saves someone else a few hours of debugging.  

Last Updated ( Sunday, 11 November 2007 )
 
Chip Music Artist of the Day: Qwan
Written by Brett Brewer   
Saturday, 01 December 2007

Today's featured artist is Qwan . His real name is Krister Kalin and he hails from Sweden. While not quite as diverse and polished sounding as our first featured artist (Nagz), Qwan is also highly beat-centric and has some really cool stuff posted at amp.dascene.net. Qwan stays close to the chiptune genre while still remaining listenable and providing enough variation to keep the songs interesting. Qwan is all over the board with his songs and you never really know what you're going to get, so you'll want to listen to at least a few songs before deciding whether you like it or not. Download Qwan's modules here. Remember, to listen to these songs, you'll need to install the proper winamp plugins such as the ones available from chipamp.org .

 

Last Updated ( Thursday, 27 December 2007 )
 
Chip Music Artist of the Day: Nagz
Written by Brett Brewer   
Saturday, 10 November 2007

In an attempt to introduce a few of my friends and associates to my new favorite genre of music known as "chip music", I'm starting a little "artist of the day" feature which will really be more like an "artist of the whenever I get around to posting a new artist" feature. 

Anyway, the artist of the day is David Halmi who hails from Hungary. On the tracker scene he goes by the name Nagz

If you like chip music that borders on hip-hop and crosses over into non-chip territory frequently, you'll love Nagz. In fact, I'm somewhat hesitant to even call it "chip music" because it's waaaay better than most chiptunes you may have heard. Like most of my favorite music, it is highly beat-centric. But unlike most of my other favorite artists, Nagz ranges over a vast mix of styles that can go from sounding like The Residents Commercial Album then to a pure videogame soundtrack, then to an ecclectic and spacey moog-like experience, then back to an angry dance beat.  You just don't know from one song to the next what you're going to get, except that it will probably be interesting and listenable.

Last Updated ( Saturday, 10 November 2007 )
Read more...
 
Bonobospants.com has officially launched
Written by Brett Brewer   
Tuesday, 16 October 2007

Greets folks. Haven't had much time to update my progress on my PHP5 certification or my Flex2 training, due mostly to huge amounts of freelance work I've been doing lately. I just launched a new web site for www.bonobospants.com which is an awesome high-end pants maker for men with athletic builds. The site rocks. I'm quite happy with the way it is coming together. We're still making some tweaks to it, but the x-cart based ecommerce frontend is up and running as is their wordpress-based blog which is customized to to send feeds with thumbnail images to the homepage. Lots of future customization is planned for this site, but check out the schweet zooming images on the product pages .

Last Updated ( Monday, 05 November 2007 )
Read more...
 
Manufacturer Copon Mod for X-Cart 4.0 and 4.1
Written by Brett Brewer   
Friday, 21 September 2007

I recently completed a small x-cart coupon mod for a UK web site called deadgoodundies.com . It gives you an additional coupon type called a "Manufacturer Coupon" which allows you to offer discounts that can apply to one or more manufacturers. There is a version for X-Cart 4.0.x and a version for X-Cart 4.1.x. The version for X-Cart 4.1 includes all the same enhanced coupon options as the "category" coupons in X-Cart 4.1. I will eventually release these mods as commercial products that you can download and install yourself, but for now, I'll have to install the mod for you. If you are interested in having this mod installed in your x-cart store, please click the "request a quote" link to the left and give me some info about your store including any custom mods you may already have that would affect coupons. In a stock version of x-cart I should be able to install the mod for a flat rate of $100, but on a hacked version of x-cart it will depend on the modifications that are already in place, so my normal hourly rates would apply. 

Last Updated ( Monday, 05 November 2007 )
 
Re-release of old Dreamweaver extensions
Written by Brett Brewer   
Friday, 24 August 2007

Due to popular demand, I have tested my old extensions in Dreamweaver 8 and since everything still seems to work, I have re-released them along with one new extension. The following old extensions have been made available:

  • PHP Alternate Table Row Color
  • PHP Alternate Table Row Color Deluxe
  • Conditional Region (Show if Recordset Field Condition is True)
  • Delete Record with Javascript confirmation

The following new extension is for people who work with PHP Smarty templates:

  • Smarty Tags and Toolbar - For anyone who works with Smarty templates in Dreamweaver, you want this extension. I found a couple of extensions written by others in the Smarty WIKI, but liked parts of both of them, so I packaged them up into a single extension with a cleaner install footprint. There's a version for FlashMX and lower and a version for FlashMX 2004 and higher. Make sure you choose the right one or you'll get startup errors after you install it.

Head on over to my downloads section to download any or all of my extensions. 

Last Updated ( Friday, 31 August 2007 )
 
Moving From Flash 8 to Flex 2: Day 3
Written by Brett Brewer   
Monday, 20 August 2007
Learning Flex2 has been a real eye opener for me. For anyone who is familiar with the older Flash component architecture (v1 and v2), you will be happy to hear that the new component architecture is much more robust and easily extended. Flex2 authors Flash9 movies with Actionscript 3. The authoring environment is based on Eclipse and existing Eclipse users can keep using Eclipse with the Flex2 builder plugin for Eclipse. Having spent countless hours configuring Eclipse for use with PHP, I chose to use the Flex2 Builder. The standalone Flex Builder appears to be very similar to Eclipse and I think it was built largely on Eclipse, so it will get you used to the Eclipse IDE conventions should you ever decide to use the full version of Eclipse.
Last Updated ( Monday, 20 August 2007 )
Read more...
 
<< Start < Prev 1 2 3 4 5 6 7 8 9 10 Next > End >>

Results 65 - 72 of 85

Search

Who's Online

We have 1 guest online

© 2017 www.brettbrewer.com
Joomla! is Free Software released under the GNU/GPL License.