The Fokker-Planck formalism for closed bosonic strings