After a period of dictatorship during the governments of Generals Miguel Primo de Rivera and Dámaso Berenguer and Admiral Aznar-Cabañas (1923–1931), the first elections since 1923, largely understood as a plebiscite on Monarchy, took place: the 12 April 1931 municipal elections. These gave a resounding victory to the Republican-Socialist candidacies in large cities and provincial capitals, with a majority of monarchist councilors in rural areas. The king left the country and the proclamation of the Republic on 14 April ensued, with the formation of a provisional government.