Big Belly Trash Cans and Usability

This is my third logbook entry for my Human-Computer Interaction (HCI) course.

A few years ago, Philadelphia replaced many of the garbage cans with BigBelly Solar trash compactors.

Big Belly Solar Trash Compactors
2 recycling bins and a solar compactor in Penn Park

I’d first seen Big Belly at a park in Chicago. It seemed like a great idea: the smart trash can compacts refuse so that it needs to be collected less frequently, and even sends out a signal to the grounds crew when it is full, so that there’s never an overflowing trash receptacle (the latter was a big problem in Philly, especially on weekends).

Time Magazine recently ran an article on BigBelly (“Trash Talk“), particularly citing their success in Philadelphia. I still think the solar compactors are a great improvement over the overflowing trash cans of years past. The streets are cleaner, and they save money. But from a resident’s perspective, I think they have room for improvement.
Continue reading Big Belly Trash Cans and Usability

Moving SharePoint sites using stsadm.exe

I recently needed to move a SharePoint site from one site collection to another. Fortunately, this is very easy to do using the stsadm tool (located in the bin directory of the 14 hive).

Following the instructions at Using Stsadm.exe to Migrate Site Data (a SharePoint 2007 document, but still applicable to SharePoint 2010), I used the stsadm export command from the 14 hive with the following parameters:

bin\stsadm.exe -o export -includeusersecurity -versions 4 -url 'https://mysite.url/oldcollection/myweb' -filename myweb.cmp

However, that returned the following error message:
Syntax error in argument: url

If you drop the quotation marks around the URL, it works:
bin\stsadm.exe -o export -includeusersecurity -versions 4 -url https://mysite.url/oldcollection/myweb -filename myweb.cmp

(I find that really unbelievable. Text parameters almost always appear as quoted values. Even if it doesn’t need the quotes, you’d still expect it to accept the quotes!)

The instructions for the export command mention cabsize but don’t indicate the default:
-cabsize <integer>
Specifies the maximum size of the .cmp file in megabytes. The range is from 1 to 1024 MB. If the export data exceeds the maximum specified, the data is split into multiple files."

For the site I was working with, the export command saved the site as 4 files, each around 25 megabytes. I decided I would prefer a single .cmp file (and the site I was exporting did not exceed 1024Mb) so I increased the cabsize to the maximum:
bin\stsadm.exe -o export -cabsize 1024 -includeusersecurity -versions 4 -url 'https://mysite.url/oldcollection/myweb' -filename myweb.cmp

To import the site into the new site collection, run the import command:
bin\stsadm.exe -o import -url https://mysite/newcollection/myweb/ -filename myweb.cmp

Once you’ve moved the site–and checked the new location to make sure everything worked–don’t forget to delete the old site and the .cmp file.

Javascript Array Sort & Random Ordering

Recently a colleague and I were looking at some Javascript code that randomizes a list of elements. The code did this by creating an array of list-item elements, and then passing a comparison function that returns a random result to the array.sort() method. Unfortunately, the random order was anything but random: after reloading the page 50 times, the distribution was skewed heavily towards the original array ordering.

In case you don’t feel like reading my entire exploration of this topic, I’ll give you the short version:
Don’t use array.sort() to randomize arrays! There are methods of randomizing arrays that produce better (i.e. more random) results, and that are (probably) faster.
Continue reading Javascript Array Sort & Random Ordering

Center City Philadelphia’s Lack of Pedestrian Signals

This is my second log-entry for my Human-Computer Interaction class this summer.

When I first moved to Center City, Philadelphia, one thing that struck me as odd was the use of regular traffic lights as pedestrian signals. Even at the intersection of two one-way streets, there would be traffic signals in all four directions. There are generally not separate pedestrian signals.


Pedestrian signals in Center City, Philadelphia

While you will find separate pedestrian signals at broad intersections, these are the exceptions rather than the rule. (Perhaps other cities do this too, but if so I have not taken notice.)

After living here for years, it very quickly becomes a part of the landscape and no longer seems abnormal. But I took notice again this year on the 4th of July: a big holiday in Philadelphia that draws a lot of tourists. I noticed a fair number of confused pedestrians, but also a couple of drivers who attempted to drive the wrong way down one-way streets.

It is a convention at most intersections in most cities that if one direction has a visible traffic light, traffic is expected to flow in that direction. Drivers from out-of-town, many of whom are not used to one-way streets, see these pedestrian signals and think they indicate the direction of traffic. But really, it’s only foot traffic, on the sidewalk, that flows that direction. Sure, there are other visible signs: one-way signs and cars parked facing only the opposite direction. In the absence of immediate oncoming traffic, though, those signals can really send the wrong signal.

Why did Philadelphia choose to use the usual automobile traffic signals for pedestrian signals? I assume it saves money: not that the signals themselves are necessarily more costly, but that one computer/controller–or perhaps a simpler controller–can manage each intersection. I don’t really know the reason, though. I definitely feel that it is a mistake to break such a common convention. On the other hand, though I have seen confused pedestrians and drivers, I have yet to see an accident caused by this confusion.Rental

Ambiguous “On” Indicators on Television Sets and Monitors

I’m currently taking a course on Human-Computer Interaction (HCI). The instructor advised us to keep logs of things we notice in the world that relate to the course material. This is one of my log entries.

One item I noticed today was the On indicator on a Samsung television at work. It’s a large flat-panel screen that we have connected to a PC for presentation purposes in a small conference room. I was preparing for a presentation and sat down at the keyboard and mouse. The power light glowed amber, so I wiggled the mouse. Nothing. I pressed CTRL-ALT-DEL. Nothing. I checked to make sure that the PC was on, and then I checked to make sure the cables were connected. Everything looked correct–why wasn’t the screen getting a signal?

Bottom panel of a television set displaying an amber light. Note that although the indicator light is near the power symbol, it could be much closer.

Continue reading Ambiguous “On” Indicators on Television Sets and Monitors

SharePoint Breadcrumb Styles

SharePoint (and .NET) has a built-in SiteMapPath control that is designed to display a breadcrumb trail.

There are a lot of options in terms of styling the breadcrumb trail, but it is not obvious how all of them are used. Even more confusing, though, is when you make a change the the styles but you don’t see that change reflected on your site. For example, on one site I am working on I saw breadcrumbs like these:

An example of SharePoint breadcrumbs
An example of SharePoint breadcrumbs

I didn’t like how much vertical space this style occupied. I wanted something a little more compact. But how to change the appearance?
Continue reading SharePoint Breadcrumb Styles

Perl error when running W3C checklink

I’m using ActiveState Perl 5.14.2 on a 64-bit Windows 7 machine. I downloaded and installed the W3C checklink package via the Perl Package Manager.

When I attempted to run checklink on the command line like this:
C:\Users\chris\>checklinks http://osric.com
I got the following error message:
"-T" is on the #! line, it must also be used on the command line.

To get this to work, I had to run the command as follows:
C:\Users\chris\>perl -T C:\perl64\site\bin\checklink http://osric.com

The -T switch is to enable taint mode, which helps protect the program from malicious input.