Browsing Category

dc

MySQL “Natural Sort” in ORDER BY

dc

I just recently had a client whose data import requirements changed mid-project. We started off with an INTEGER field for this particular value because it made the most sense. Once I got the real data from the client I found out that that there are duplicate pages (representing multiple items on a page) and some … Continued

Zend Framework 1.11 + PHPUnit 3.6 unit testing

dc

At work we are up to date with PHPUnit  at 3.6, yet officially ZF1 will only support PHPUnit 3.4. Looking through the code there is some support for PHPUnit 3.5, but I actually make use of the additional assertions that PHPUnit 3.6 provides. Initially I had intended on just extending the Zend_Test PHPUnit classes but I … Continued

PHP5 cronjob in Debian packages

dc

WTF! The /etc/cron.d/php5 should be optional and not forced upon you. This has bitten me twice, once at work, and now on my business machines. It isn’t funny, and there is really no need for it. If you are doing it “for the users”, then let the idiots have massive session caches. It is THEIR … Continued

jQuery UI Datepicker Month only option

dc

A client requested that we have the ability to choose only a month/year in the jQuery UI Datepicker module while retaining the ability to select a specific date. After searching the internet I determined that the best way to do this is just to modify the jQuery UI Datepicker and directly inject a button. jquery-ui-datepicker-monthonly-1.0.0 … Continued

IE7/8 .text() vs .html()

dc

So .text() doesn’t work for retrieving the content. The solution use .html(). The problem with this is that in IE 7/8 you end up with extra white space in the content. The solution $.trim(), and now you have your content the same as modern browsers using .text(). This stumped me long enough while using a … Continued

gallery 2.2.1 with gnome 2.16.2

dc

This is a re-post from my MySpace blog. UPDATE 1: While I haven’t tested it this bug appears to be fixed as of 2007-06-11. UPDATE 2: SourceForge uses better urls now. Not sure when this was changed. I thought I would download the new Gallery 2.2.1 and use webDav. They need better setup instructions. Basically … Continued

nullfs and sockets

dc

This is a re-post from my MySpace blog. UPDATE: This was fixed far better than I did it at the time in the stable/9 branch as of 2012-04-24 What happens on FreeBSD 6.x series machines using nullfs and sockets? At least in my current setup it fails. The scenario is that I am running mysql … Continued

subversion and stunnel

dc

This is a re-post from my MySpace blog. After a couple of days of trying I finally figured out how to use stunnel with subversion. Then after I managed to figure it out I decided I would check the mailing lists and the bug tracker. someone already managed to do the same thing. I however … Continued

Flash 9 upgrade

dc

This is a re-post from my MySpace blog. If you want a better web surfing experience turn flash OFF. It sounds crazy but since I’ve converted my laptop from WindowsXP Pro to FreeBSD (6.1) and I’ve refused to install linux compatibility on my laptop, I have not had flash available at all. It does make … Continued