Re: selector caching, chose to omit it to reduce the line count, knowing that the performance hit was there. I can add it in though.

Re: using map instead, the version of jquery being used doesn't support arrays from being used in append. Do you know of another way to do so?