The Islamic Republic Party was Iran's ruling political party and for years its only political party until its dissolution in 1987. After the war, new reformist/progressive parties had started to form. The country had no functioning political parties until the Executives of Construction Party formed in 1994 to run for the fifth parliamentary elections, mainly out of executive body of the government close to the then-president Akbar Hashemi-Rafsanjani. After the election of Mohammad Khatami in 1997, more parties started to work, mostly of the reformist movement and opposed by hard-liners. This led to incorporation and official activity of many other groups, including hard-liners. After the war ended in 1988, reformist and progressive candidates won four out of six presidential elections in Iran and the right-wing nationalist party of Mahmoud Ahmadinejad won twice.