Chess using JavaScript with jQuery and jQueryUI