HARRISBURG, Pa. (WHTM) — A man wanted on charges including kidnapping and attempted homicide after two boys were abducted in Harrisburg was taken into custody without incident on Friday afternoon, Harrisburg City officials said.

Pennsylvania State Police issued an Amber Alert Thursday morning for two boys who were last seen in Harrisburg. That Amber Alert was canceled shortly before 9 a.m. when police said the children were located safe, about half an hour after it was issued.

“We didn’t want to do that prematurely and we wanted to have all the information, that way we could blast it out,” Capt. Terry Weland said.

Police were searching for a 4-year-old boy and a 5-year-old boy who had last been seen in a vehicle near the intersection of 20th and Holly streets in Harrisburg City, around 5 a.m. on Oct. 27.

The vehicle was being driven by 39-year-old Kenneth Smiley, according to state police. Harrisburg Police alleged that Smiley, who was driving a black Nissan Maxima, forcibly took the children of the woman who had contacted police. Police said Smiley is the father of one of the boys.

According to police documents, the woman told police she woke up in the middle of night to find Smiley sitting on her bed. She said she started waking her kids up, but said Smiley follwed her with a knife.

Documents allege Smiley tried to strangle his 4-year-old child and tried to suffocate him with a pillow. Police said he also grabbed the other child, a 5-year-old boy, by the hair and leg, then forced both children and their mother into her car. The woman told police Smiley told them “they were gonna die tonight.”

The woman told police she tried to get out of the car while Smiley was driving and eventually fell out after she said Smiley tried to keep her in. A witness saw that and called 911.

“A very active investigation” occurred for several hours Thursday morning as police searched for the children, Smiley, and the car, according to the Harrisburg Bureau of Police. Around 8:15 a.m., a Harrisburg City police officer spotted the vehicle, according to the bureau.

The vehicle was found parked in the 200 block of S. 19th Street occupied by the two boys, who were unharmed, Harrisburg Police said. Smiley was not there, police said. Harrisburg Police said they were transported to a hospital for a precautionary evaluation.

The Harrisburg Bureau of Police said Smiley was wanted on charges of criminal attempted homicide, burglary, kidnapping, strangulation, aggravated assault, terroristic threats, and simple assault. He was also a wanted absconder from Pennsylvania State Parole, according to police.

Smiley was taken into custody around 2 p.m. on Oct. 28 in the area of Kline Plaza, Harrisburg City officials said on Friday. City officials said police received and acted on an anonymous tip, and Smiley was being taken into booking around 2:50 p.m.

A warrant was previously issued for Smiley’s arrest following an earlier incident involving him and the boys’ mother, according to Harrisburg officials. Court documents say that on Oct. 9, Smiley allegedly hit the woman in the face during that argument, according to the documents.

The next day, Oct. 10, Smiley allegedly threatened to shoot the woman while she was dropping her child off at daycare and smashed her car windshield, according to police documents. Harrisburg officials believe the child was likely one of the same boys involved in the kidnapping on Thursday, Oct. 27.