People look at a massive fissure that opened up in a road in Mirpur, Pakistan-Administered Kashmir, when a powerful earthquake struck the region on September 24, 2019. REUTERS

Islamabad — A powerful 5.8 magnitude earthquake struck northeast Pakistan on Tuesday, damaging dozens of homes and shops and killing at least 19 people and injuring over 300, officials said. According to state-run Pakistan Television, four children were among the dead in Mirpur, a town in the Pakistan-administered part of Kashmir.

Raja Qaiser, a deputy commissioner in the region, said rescuers were still transporting victims to hospitals in the city, where an emergency was declared.

He said a main road near Mirpur was also badly damaged, causing accidents and damaging buses and other vehicles.

Get Breaking News Delivered to Your Inbox

TV footage showed damaged homes, shops and vehicles in Mirpur, where a breach at a main canal was submerging villages.

According to Pakistan's Meteorological Department, the epicenter of the 5.8 magnitude quake was located near the mountainous city of Jehlum in eastern Punjab province. The earthquake shook walls across the country and left people waiting in the streets fearing further tremors.

Residents in Islamabad were seen rushing out of multistory buildings into the streets.

People stand outside their office after an earthquake was felt in Islamabad, Pakistan, September 24, 2019. AP

Shortly after the tremor hit, Pakistan's military dispatched troops and medical teams to the quake-affected area to assist civilian authorities in helping victims.

Authorities said helicopters will also be used if needed to evacuate people from the earthquake-affected area.

Some residents in Mirpur said shortly after the quake struck, they came out of their homes reciting verses from the Quran, Islam's holy book.

"I was sitting in my shop when suddenly the walls started swaying. I knew that it is a strong earthquake. The moment I came out of my shop, its roof caved in," one shop owner told Pakistan's Geo news channel as he stood in a street littered with debris of houses and nearby damaged shops. The shop owner was not identified.

Mohammad Arif, whose home was damaged in Mirpur, said when the quake hit, he started shouting to alert his family.

"God saved me. God saved all of my family members, but our home was partially damaged," he told Geo.

Mushtaq Minhas, information minister in Pakistan-held Kashmir, told reporters that rescuers were still using ambulances to transport the injured to hospitals.

Pakistan Prime Minister Imran Khan and President Arif Alvi in separate statements expressed their grief over losses caused by the quake.

The temblor was also felt in the northwest and in many towns and cities in eastern Punjab province.

A magnitude 7.6 quake in 2005 killed thousands of people in Pakistan and Kashmir.