Changed click routines to not use JQuery

First stage of JQuery removal