Iran and Iraq both reported heavy new fighting in the Persian Gulf war yesterday, as the commander of the Iranian Army warned that his country was willing to strike all the way to Baghdad to overthrow the government of Iraqi President Saddam Hussein.

Iraq, in a military communique, claimed a major victory saying its forces trapped 100,000 Iranian invaders in a massive ambush that left thousands of casualties and sent the survivors fleeing back to Iran.

A group of foreign correspondents yesterday were taken by Iraqi military officers to an area near the Iraqi city of Basra and reported they saw evidence that a big battle had been fought there.

The official Iraqi news agency said 2,300 Iranians had been killed and a large number captured in fighting during the previous 24 hours.

These reports contrasted with an Iranian military communique that said Iranian troops and helicopters destroyed two Iraqi brigades and a battalion, inflicting 850 Iraqi casualties, according to Tehran radio. The communique also reported that 116 Iraqi tanks and armored troop carriers had been knocked out on the fifth day of the Iranian offensive into Iraq. Iran has not allowed reporters to go to the front, and there was no way of independently verifying these claims.

Peter Nettleship, a correspondent for the British Broadcasting Corp., was among the reporters taken to the front in Iraq and said in a dispatch carried by The Associated Press that the Iraqis claimed the Iranian invasion force had been "lured into a trap" with their retreat cut off by by a lake.

"The Iraqi colonel guiding our party said there are now no Iranian positions on Iraqi soil," Nettleship reported. "But he said heavy fighting was still going on across the border, and we heard almost continuous artillery fire throughout our visit.

"We were shown the farthest point Iranian troops had reached, a pumping station controlling a huge artificial lake."

Nettleship said the reporters were taken farther north where they were shown about 20 captured Iranian tanks. "South of Basra, 800 Iranian prisoners were lined up in the 112 degree sun for our inspection. Some looked very young, under 16 I would say," the BBC report said.

But the Iranian communique insisted Iranian forces remained inside Iraq and were consolidating their positions after inflicting "crushing blows" on the Iraqis.

In Tehran, Col. Sayad Shirazi, the Iranian commander, told the newspaper Ettelaat that Iranian forces would not end their offensive until Saddam Hussein is overthrown.

"Operations will continue until we win a final victory," Shirazi was quoted as saying. "Our intention and target is to find him and also to find an overland route to reach Jerusalem. It may pull us to move toward Baghdad."

The speaker of Iran's parliament, Ali Akbar Hashemi Rafsanjani, warned that Iran would retaliate against any Persian Gulf state that supplied arms to Iraq, Tehran radio reported. His remarks came a day after Iraq's deputy prime minister, Taha Yasin, left Baghdad to visit Saudi Arabia and Kuwait seeking new aid for the beleaguered Baghdad government.