improved jQuery setup