22 January 2008

Data is the New Long Distance

I just finished a two year Verizon Wireless contract. They frantically called me, informed me my contract was up, and walked me through a month-to-month agreement. The only change was that their "Mobile Web" feature went from $5/monthly to free. Free! Sweet! Then I listened to the big long details where the customer service rep informed me they didn't debit my airtime minutes for the usage. Charges now run $1.99/megabyte for Mobile Web usage unless you spend $15+ monthly on an all-you-can-eat option.

That straw, the allure of SIM cards, and the fact that Verizon has the lousiest, P.O.S. software on their phones (contact me if you're interested in a rant) made me switch to at&t yesterday. I paid attention to at&t's data charges— either $15+ monthly for a smörgåsbord or $0.01/kilobyte. Similarly crazy in price.

An example of the sheer monstrosity of it all:

  • Assume you didn't pay the $180+ annually these companies want for unlimited data plans
  • Assume you bought a 2 gigabyte microSD card for your phone.
  • Assume you filled up your microSD card
All of these seem reasonable. After all, you're already paying hundred of dollars annually to be able to use the phone you've purchased. For 2 gigabytes/2,048 megabytes/2,097,152 kilobytes of a la carte data:
  • Verizon would charge you $4,075.52 to fill a 2 gigabyte microSD card at $1.99/megabyte.
  • at&t would charge you $20,971.52 to fill a 2 gigabyte microSD card at $0.01/kilobyte.

The wireless carriers may rationalize this ridiculousness by saying that they can better forecast data network needs when customers buy unlimited plans. But then again, how much forecasting information do you get on "unlimited" plans?

Monthly a la carte data plan pricing should cap out at the monthly unlimited plan rate. After using $15 bucks of a la carte data in one month, just bump me to unlimited already. Say that up front. Don't be shady. Sheesh.

20 January 2008

Manipulating amarok remotely using dcop and ssh

Following my friend Ian's recommendation, I moved all of my music onto an amarok installation a couple of years back. Great program, great features, simple to use, nicer for multi-user installations since the database can be shared, able to have automagic playlists like what-haven't-I-listened-to-in-awhile, etc. I can't recommend it highly enough.

Often, I play music from our desktop but work on my laptop. With purely random playlists, two problems arise when listening remotely:

  1. Ack! That's horrible. Next song, please.
  2. What song is this exactly?

Amarok provides an dcop interface that allows CLI access to lots of information. If your remote SSH shell isn't part of the same dcop session (not likely), you need an extra bit of magic to use it.

In my setup, I can answer those two problems with these commands:

  1. dcop --user `whoami` --all-sessions amarok player next
  2. dcop --user `whoami` --all-sessions amarok player nowPlaying
and can setup a remote 'tail' with a fancy one-liner like: while echo -n; do for info in path year artist album track title rating sampleRate score labels trackPlayCounter; do echo -en "${info}:\t"; dcop --user `whoami` --all-sessions amarok player ${info}; done; sleep 10; clear; done where the --all-sessions option solves the different-dcop-session problem and --user `whoami` is required alongside it.

07 January 2008

Vacation Shorts

A small collection of short videos taken while on vacation with Michelle. When happy or hyperactive, she can be hilarious to watch.

Give Me Spinning

Taken shortly after New Year's while visiting a friend in Santa Cruz, we stopped at a park. It was raining, windy, and getting nastier. Straight from the car, Michelle took off frolicking:

Eating Donuts in College Station

Taken while on a Nutcracker Bon-Bon audition trip to College Station, TX, we stopped at a donut shop one morning. Notice the 2 and a 1/2 step donut eating maneuver, and the huge grin she gets once the bite is safely performed:

Poo on Your Jeans

Taken outside some of the bigger museums in Amsterdam, Michelle calmly notices that I've got dog crap all over my left pant leg:

23 December 2007

Thoughts on ExpressionEngine 1.6.1

I spent the week after finals putting together a support site for a friend's company. His company chose ExpressionEngine version 1.6.1 as the underpinnings of the support site. I'd never used it before, and here are my thoughts on the system having stared at it for a week straight:

ExpressionEngine Pros

ExpressionEngine had a lot of good things to offer, and I can't imagine having completed as much of the support site as quickly as I did without it:

Simplicity of the Templating System
From looking at the shipped, default templates it was straightforward to learn ExpressionEngine's template syntax. Tags come in {single} instances and in {pairs}{/pairs}. Compared to all the JSP line noise I've used in the past (e.g. <%jspTag%>) it was nice to have a bracket just require a bracket.
Flexible URL Parsing
Within any template, it's possible to extract URL segments to dice your incoming URL into manageable pieces. In the knowledge base we had URLs like knowledge_base/category/category_id and we pulled them apart with ExpressionEngine's {segment_#} construct. That was the only place where surgery was required. The rest of the time the URL parsing just worked and I didn't have to think about it. Within the bug tracker pages, I could request a single bug using URLs like bugs/bug/bug_id or bugs/bug/bug_title. I could see all the current bugs using bugs/bug/ with no trailing identifier. The underlying page to do both was identical, and ExpressionEngine handles the URL details automagically within it's underlying Weblog Entries and Comment handling tags.
Search Capabilities
ExpressionEngine has a great Search Module that makes it simple to search across all the content on the site. I doctored the example Simple Search Form provided in the documentation to automatically search across all entry text and titles (default is just titles I believe) and to provide AND semantics for multiple keywords. The advanced search form was also easy to tweak to get good defaults set. After configuring the Excerpt setting I could get a snippet of each search result using {excerpt}. I needed {exp:word_limit total="25"}{excerpt}{/exp:word_limit} to keep the results page from getting too lengthy.
Flexible Entry Categorization
Though the system allows hierarchical categories (e.g. category Sub-A is underneath category A) any entry could be filed under multiple categories simultaneously and subsequently accessed from any of them. For the knowledge base this let us put answers to questions in multiple places, and gave us a navigable ontology for people to use.
Funky Characters and Escaping
While entering fake articles for testing, I got bored with regular lorem ipsum greeking and decided to use some actual greek characters. The system handled it without a hiccup.
Great Public Support Site
The ExpressionEngine Support Site is top notch. Be sure to search both the forums and the knowledge base when you're digging for information.

ExpressionEngine Cons

With the caveat that these issues are likely fixable but just difficult for the uninitiated, these were my gripes about using ExpressionEngine:

Lack of Formality in the Templating System
I ran into odd problems when I tried to use nested conditionals, and I never could find what I'd call a "language reference" that'd give me a definitive answer for what works and what doesn't. Basic control structures were hard to read about because they've been given wacky names, e.g. this {if something}{/if} is an if statement not a conditional global variable. The ExpressionEngine template documentation lies somewhere between an extended example and a thin, wordy book sorely in need of a good index. There is a quick reference but it looks like you'd expect for a PHP-based system— lots of variable/tokens in a laundry list with little semantic/syntactic context. I prefer working from dense, highly structured references like O'Reilly Media's Nutshell Series and Visibone's Reference Products.
Breadcrumb Navigation and/or Advanced Category Functionality
Within our knowledge base, we wanted to provide a breadcrumb trail for how the user navigated into the given article. That would let the user back up by category if he or she got too far in. Unfortunately the ExpressionEngine documentation and knowledge bases keep mum while the forums are littered with poor information on creating breadcrumbs. The consensus there is that a one-size-fits-all breadcrumb mechanism doesn't work, and that everyone generally needs to roll his own. Okay. But, the existing category support tag doesn't answer questions like what-is-the-parent-category-of-the-current-subcategory? (or, if it can, the documentation isn't giving up its secrets lightly) and so we had to roll our solution by querying directly against the underlying database tables.
No External Member Registry
Since we were creating a support site for an existing user base, we wanted to use login information from our application to provide user accounts for the ExpressionEngine-based site. No dice. There are import mechanisms, but they run the risk of drift/synchronization issues over time. External user registries are apparently possible but wholly unsupported. The hacks the friend put in place are working but temporary to say the least.

I've got some other minor nits, but they are of the I-didn't-expect-it-to-work-that-way variety and wouldn't matter if I spent a second week using the product.

Verdict

ExpressionEngine is a good product, and I'd choose it if I ever have to roll another site.

Random Tips

When alternating CSS classes in an HTML table, don't look for a modulus operator to write something like {if count%2}{/if} to use in conditional statements. It doesn't exist. Instead, use the {switch} variable.

Put your templates on the filesystem otherwise you're going to edit everything from within an HTML <textarea>. That's painful, especially if you want to want to use external source control and/or you've invested time in becoming proficient with a text editor. If that's not an option, the Firefox It's All Text! extension will help dull the pain.

When you create a new weblog, be sure to associate the "Default Status Group" with it right away (i.e. EE Control Panel > Admin tab > Weblog Administration > Weblog Management > Edit Groups). If you don't trying to use a Stand-Alone Entry Form will mysteriously cause all new non-SuperAdmin user posts to have "Closed" status no matter how you fight with it. After two hours of muttering under my breath, I gave up and read the source code only to find// if there is no status group assigned, only Super Admins can create 'open' entries. Not assigning a status group causes your weblog to have "Open" and "Closed" status available, which is identical in behavior to having the "Default Status Group" assigned save this nasty catch.