BAKU, Azerbaijan — The mayor of Azerbaijan's second-largest city has been shot and wounded in an attack that also wounded his bodyguard.

The Interior Ministry said Elmar Veliyev, the mayor of Ganja, was attacked outside his office late Tuesday. It said in Wednesday's statement that the gunman was arrested by police. His motives weren't immediately clear.

Veliyev and his bodyguard have been hospitalized with gunshot wounds and are in stable condition.

Authorities said that President Ilham Aliyev has taken personal control of the investigation.

Ganja, a city of 330,000, is located in western Azerbaijan.