Phase transition in swollen gels