Fixing some jquery issues