Updated

French police stormed a bank and captured a gunman who took four of its employees hostage Wednesday while claiming he was acting for religious reasons. The six-hour standoff jarred a region still reeling from a terrorist shooting spree that killed seven people earlier this year.

But prosecutors waved off French media reports that the latest suspect had ties to the Al Qaeda terror network, saying he had psychiatric problems.

The hostages in Toulouse were released unharmed, while the suspect was hospitalized with two bullet wounds in the left hand and the left thigh -- neither of which were life-threatening. Prosecutor Michel Valet said the gun, used twice during the ordeal, fired only rubber bullets, and that the gunman had no prior police record.

Valet refused to identify the suspect by name, confirm French media reports that he was 26, or name what religion the suspect referred to in making his claims.

"I am not a doctor, but we have objective elements that allow us to think and affirm that we're dealing with someone who suffers from considerable psychological problems and that his act is linked to these problems," Valet said.

"The claims of responsibility centered on badly defined, badly expressed religious claims and right now it is difficult to know what guided his behavior, which was anything but rational," he added.

Tensions have been high in Toulouse since March, when a gunman who police said claimed links to Al Qaeda killed three Jewish schoolchildren, a rabbi and three paratroopers in the area. Those were France's worst terrorist attacks in years, and led to a crackdown on suspected Islamist radicals around France.

The CIC bank branch targeted Wednesday is in the same neighborhood where Mohamed Merah, the suspected gunman in the March attacks, was shot and killed by police after a long standoff. It also is near the police station where authorities were overseeing the operation to surround and negotiate with Merah.

In Wednesday's incident, the gunman the bank at about 11 a.m. (0900GMT) and took the bank director and three other bank employees hostage, police officials said. Authorities evacuated and cordoned off the neighborhood and began negotiations with the gunman, who released two female hostages mid-afternoon.

The Prefect of the Haute-Garonne region, Henri-Michel Comet, said 150 police were mobilized, 30 of them from the elite GIPN squad.

Valet said that during negotiations, the gunman said he wanted to advertise the religious motivation behind his act. "The hostage-taker ... wants us to make it known that he is acting not for money, and that his motivations come from his religious conviction," Valet told reporters at the scene.

Gunshots were heard from the site around the time the gunman was captured at around 5 p.m. local time (15.00 GMT).

French President Francois Hollande issued a statement praising the "professionalism" and "efficiency" of the police involved in the raid, but the incident deeply shook many area residents.

Doriane Clermont, 23, lives across the street from the bank with her 3-year-old son and told RTL radio she's "thinking of moving."

"I'm worried about the climate that reigns in this city," she said, waiting behind the police barrier to be able to return home after she was evacuated.

Resident Maria Gomes was similarly unsettled.

"We were walking when we heard great agitation in the neighborhood, with police cars," she said. "Fear is coming back, after the Merah affair."

Among those evacuated were 4-year-olds and 5-year-olds from a private language school next to the bank. Valerie Ruckly-Gravier, who heads the Happy Momes school, or Happy Kids, said police advised that the security parameters in place could last throughout the day.

The Paris headquarters of cooperative bank CIC was in contact with police in Toulouse, bank spokesman Bruno Brouchiquan said. The bank describes itself as the second-largest retail bank in France and the leading bank insurance group, with thousands of branches in France and around the world.

The hostage-taker said he wanted the elite RAID national police force to come negotiate with him, police said. In March, the RAID police force led negotiations and a 32-hour standoff with Merah, a Frenchman of Algerian origin, in his Toulouse apartment. Merah was shot in the head in a gunfight at the end of the standoff.

French authorities described Merah as an Islamist radical who had trained in Afghanistan and Pakistan. French intelligence officials said at the time that they found no operational ties between Merah and Al Qaeda despite his claim.

His brother is in custody after being handed preliminary charges of complicity to plot the killings at a Jewish school in Toulouse and of paratroopers in Toulouse and nearby Montauban.

Wednesday's hostage-taking came amid heightened concerns in France about homegrown radicals following the Merah affair. Pakistan announced Wednesday that authorities have arrested a Frenchman reportedly linked to one of the masterminds of the Sept. 11 terrorist attack.