Easy to shaking with library csshake with function cssShakeToggle and jQuery plugin csshake.