Improved client side, added jquery for it