A professor at the University of Prague in 1882, four years later Masaryk helped expose as forgeries a group of medieval Slavic manuscripts that had been the underpinning of Czech cultural nationalism. An advocate of democratic reform and Czech autonomy within Austria-Hungary, he founded the Progressive party in 1900. With the outbreak of World War I, Masaryk began working for Czech independence in union with Slovakia. With the establishment of Czechoslovakia after the war, Masaryk was elected the republic's first president. Re-elected three times, he had mixed success in attempting to make his country a model democracy.