noodling around in javascript