Thanks, asnow, the first edit was definitely not my best work.