Deploy CakePHP on Heroku

Heroku’s not just for Rails anymore, folks. If you’re more PHP-inclined and lean toward frameworks such as CakePHP, you might enjoy trying Heroku’s current Celadon Cedar stack as your platform.

Here I’ll step through the Blog Tutorial in the the CakePHP Cookbook, with the few extra steps needed to get it running on Heroku. As prerequisites, you should be familiar with this tutorial in its generic form, and with the basics of using Heroku.
Continue reading

vshadow.exe can’t be run under WOW64

I use the Microsoft-provided vshadow.exe tool to script some backups, but I got an error when trying to run it on a Windows 7 x64 machine:

ERROR: COM call "m_pVssObject->InitializeForBackup()" failed.
- Returned HRESULT = 0x80042302
- Error text:
- Please re-run VSHADOW.EXE with the /tracing option to get more details

That error is obviously unexplanatory, but some investigation led me to deduce that you can’t run the 32-bit version of the tool on a 64-bit version of Windows. The fix is to download the Windows 7 SDK, install the “Developer tools” portion, and dig the 64-bit version of the tool out from %ProgramFiles%\Microsoft SDKs\Windows\v7.0\Bin\x64\vsstools\vshadow.exe.

If you were Googling that error code, I just saved you some time. You’re welcome.

Styling WordPress 2.7 author comments

Note: this site no longer uses the native WordPress commenting functionality, so the feature described below can’t be seen here.

Styling post author or registered user comments on your WordPress 2.7 blog is much easier than it was back in ol’ 2.6. The new wp_list_comments() template tag (or comment_class() if you’re doing it the hard way) automatically includes class names like byuser and bypostauthor for easy CSS styling. Slick.

See the official 2.7 theme migration guide for more details.

Hide yourself from your own website’s Google Analytics using Firefox

The latest version of Firefox add-on Adblock Plus includes a useful new feature that is perfect for preventing your own visits to your website from appearing in Google Analytics.

If you use Analytics on your website(s) — particularly on very small sites such as this one, where your own visits can significantly skew any traffic measurements — you have probably wished you could reliably exclude your internal page views from your traffic reports. Google provides a filter system, but it falls a bit short if you aren’t visiting from a static IP address.

Aa great solution has just arrived in the form of Adblock Plus version 1.0.1, which finally provides the ability to restrict the domains to which its ad-blocking rules apply.

After installing the Adblock Plus extension, add a filter rule of the syntax$

(replacing with your own domain). Now, when you visit your own site, you will remain completely hidden from Google Analytics.

You could undoubtedly apply this to other hit counters; Analytics just happens to be the service I use.