Fixed jquery scoping.