jquery stuff, generalize cancel button