JavaScript: jQuery function with $ in scope.