Sorry, it’s been a while. I’ve been busy at work, I’ve been wringing every last bit out of summer on my bike, and I’ve spent a lot of my free time on my upcoming CSS presentation, so I haven’t been posting as much as I would like. Fall is here. Which means I should have more time for writing. That’s cool.
Anyway, to break the ice here are a few articles that have recently caught my attention. Read the rest of this entry »
Peter Merholz from Adaptive Path talks up analytics. Don’t I feel like a smart guy with all my fancy analytics experience?
That’s probably something I don’t talk enough about here- analytics. I’ve got a ton of experience with both Omniture and Google Analytics, doing some pretty advanced work. I should share that.
Anyway, good article talking about the UX benefits of analytics data. Check it out.
This is a little resource page from one of the WordCamp Boston Ingite talks. WordPress Short Codes are clearly awesome and I don’t use them enough. I aim to change that.
I saw this tweet yesterday and was reminded , once again, of how misunderstood the return value of a DOM method like document.getElementsByTagName is. Normally, it doesn’t matter that folks don’t really understand the return value fully, because most of the time the code just works. Where it breaks is interesting, so it’s worth taking a look at it in a little bit of depth.
Typically people do things like this:
var anchors = document.getElementsByTagName('a');
for (var i = 0; i < anchors.length; i++) {
anchors[i].addEventListener("click", beAwesome, false)
}
Common pattern. Get a list of the anchors on the page, loop through and add an event to each.
If asked, I’d be willing to bet most people would assume that the list they’re interacting with is an Array. It’s got a length and you can index it- that’s got to be an Array, right?
Yesterday I was wondering why obj.getElementsByTagName wasn’t working in Safari/WebKit on a tag with a namespace prefix. I wondered, aloud, whether or not it was just something I was ignorant of.
It turns out that was the case. Dom Level 2 added new namespace specific methods to search through documents or document fragments for tags of a specific NameSpace. I’d just never had to use them before. Learning that greatly simplified the hacky code I wrote yesterday. Here it is, new and improved: Read the rest of this entry »