Evolution of the real-space correlation function from next generation cluster surveys.vRecovering the real-space correlation function from photometric redshifts