The suspected gunman, Edward Archer, 30, was charged with attempted murder, aggravated assault, assault on a law enforcement officer, recklessly endangering another person, possession of an instrument of crime, violation of uniform firearms act and related offenses, the Philadelphia Police said today.
He is being held without bail, the District Attorney's Office said.
Philadelphia Police Captain James Clark said the suspect "stated that he pledges his allegiance to Islamic State, he follows Allah and that is the reason he was called upon to do this."
The suspect used a stolen police firearm and fired shots at close-range at Officer Jesse Hartnett while he was in his police vehicle Thursday night, police said. The weapon was stolen in 2013, police said.
"You can see the male in question going toward police officer Hartnett. ... He is literally inside that car," Ross said of an image of the shooting.
The gunman fired at least 11 shots, seriously wounding the cop, and then fled, authorities said. Harnett, a 4-year veteran of the department, got out of his car and chased the gunman, firing back at him.
"His will to live undoubtedly saved his life," Ross said.
Archer was hospitalized to be treated for a gunshot wound and later released, police said today.
Hartnett, 33, was shot three times, Ross said, noting he suffered serious injuries that will require multiple surgeries. He was in critical but stable condition, police said today.
"This could have easily been a police funeral," said Ross.