He studied in Brașov and in a private boarding school at Sibiu. He continued his education at Cluj and at the University of Vienna, where he took a doctorate in philosophy. In 1848, he was in Bucharest, a participant in that year's revolution, but fled to Sibiu for a few months after the city was occupied by the Ottomans. He later returned to Bucharest and in 1851 moved to Craiova, where he became director of the Central School, which had shut down during the revolution. In 1853, early in the Crimean War, the Russian Army closed the school and turned it into a hospital. Fontanin protested and was imprisoned for seven months, but managed to reopen the following year. He ardently supported the Union of Wallachia with Moldavia, and in 1857 presided over the election of Dolj County deputies for the ad-hoc divan.