Two teenage boys were injured when gunfire erupted outside a high school football game between Simon Gratz and Imhotep Institute Charter in the city’s Nicetown section Friday night, police said.

The shooting occurred about 7:40 p.m., during the second quarter of the game, just outside Marcus Foster Memorial Stadium at 1600 Straub St., between Germantown Avenue and 16th Street, police said. The gunfire put a stop to the game, as fans left the bleachers and ran across the field to escape.

A 14-year-old boy was shot in the left foot and a 15-year-old boy was shot in the left thigh. Both victims were taken to Einstein Medical Center and were listed in stable condition.

Nick Lincoln, Imhotep’s football coach, said his team was leading by 19-0 with eight minutes left in the second quarter when he heard gunfire coming from the street behind the stands.

“Everybody [in the stands] ran out of the stadium,” Lincoln said. The players ran off the field toward the locker rooms.

Lincoln praised security officers for both schools for getting the teams out of the stadium. “Everybody’s safe,” he said.

Police reported no arrests or motive for the shooting. Acting Police Commissioner Christine M. Coulter visited the stadium to speak with investigators, but few details were available.