Make overlay work with jquery 1.10