jquery version of the atm