ISTANBUL, Turkey - Parliament yesterday approved a constitutional amendment to elect Turkey's president by a popular vote, giving even greater weight to midsummer elections that are already shaping up as a divisive referendum on the role of Islam in government.

The 376-1 vote by lawmakers opens the door to holding presidential and parliamentary elections simultaneously, on July 22. However, the package of electoral changes still could be blocked by a veto from the country's resolutely secular president, with whom the ruling party is at odds.

Under the measures, the president for the first time would be elected by a popular vote rather than by parliament, and could serve up to two five-year terms rather than a single seven-year one.

Lawmakers' terms would be shortened from five to four years, and it would be much easier for the majority party to muster a quorum in parliament - an issue that took on outsized importance in recent weeks amid a polarizing struggle over the presidency.

The ruling Justice and Development Party, known by its Turkish initials, AKP, believes the changes will help solidify its hold on power. The vote represented a victory for the party, which has its roots in political Islam, after an unexpected political battering over the last month.

Turkey is embroiled in a bitter political confrontation that was sparked when the ruling party tried to put forth a candidate to replace President Ahmet Necdet Sezer, whose seven-year term in the largely ceremonial post was to have ended May 16.