Original: With secularization in 1848, the buildings became a teachers' school.
Simplified: Because of secularization in 1848, the buildings became a school.