fix the javascript table