At least 10 members of Afghanistan's security forces have been killed in clashes with the Taliban in the central province of Wardak, officials say.
The officials were quoted as saying on October 7 that the militants destroyed highway bridges during their assault, which was launched late on October 6.
Government forces repelled the attack but gunbattles were still under way, according to Interior Ministry spokesman Najib Danish.
A spokesman for the provincial governor said the attackers destroyed checkpoints and set fire to a government building in Sayeed Abad district.
The spokesman, Abdul Rahman Mangal, also said that the district police chief was among the 10 officers killed in the violence.
He added that Afghan forces counterattacked to stop the militants from approaching the city.
Officials said at least 25 Taliban insurgents were also killed in the fighting, and reinforcements were deployed to regain control of the contested highways.
Meanwhile, Afghanistan's power supply company, Da Afghanistan Breshna Sherkat, said power lines serving Wardak and Ghazni provinces had been cut. Supplies were also affected parts of the nearby provinces of Logar and Paktia.
Teams will be sent to repair the lines as soon as security improves, according to a statement.
A statement from Taliban spokesman Zabihullah Mujahid said the militants seized the center of Sayeed Abad and the surrounding security checkpoints.
Provincial council member Haji Ahmad Jaffari also said that the Taliban already captured the district and that reinforcements from the provincial capital, Maidan Shar, were on their way.
However, another council member, Hussain Ali Ballegh, denied that.
Some reports said the attackers destroyed a highway bridge, cutting off road traffic between the national capital, Kabul, and the provinces of Ghazni, Zabul, and Kandahar.
Taliban militants and the extremist group Islamic State have a staged a number of deadly attacks across Afghanistan ahead of nationwide parliamentary elections set for October 20.
More than 2,500 people, including 418 women, are competing for the 249 seats in Afghanistan's lower house of parliament, the Wolesi Jirga.
Some 54,000 members of Afghanistan's security forces will be responsible for protecting polling centers on election day.
More than 2,000 polling centers will be closed for security reasons.
Afghan security forces have struggled to counter attacks from militant groups since the withdrawal of most NATO combat troops in 2014.