By Steve Beck, Dray Clark, Jenn Bernstein

PHILADELPHIA (CBS) — A student was taken into custody Wednesday morning after he tried to bring a loaded gun into a high school in Northeast Philadelphia, school officials say.

READ MORE: Abortion Rights Advocates Gather For Bans Off Our Bodies Protest In Philadelphia After SCOTUS Overturned Roe v. Wade

The incident happened about 7:20 a.m. at Samuel S. Fels High School in the 5500 block of Langdon Street.

According to investigators, an 18-year-old student, identified by police as Shaheed Whack, entered the school building and placed his backpack down to be examined by the metal detector x-ray machine. The machine spotted the gun inside the backpack and police say Whack then took off and ran out of the school.

School police officers chased after the student and he was eventually apprehended minutes later near the school.

Philadelphia police officers took Whack into custody and he was taken to Northeast Detectives for processing.

Investigators say the gun found inside his backpack was a loaded .38-caliber revolver.

Police say Whack was still in custody at Northeast Detectives Wednesday afternoon, and is facing gun charges.

READ MORE: Brandywine Valley SPCA, Other Shelters Holding Mega Adoption Event This Weekend

“It’s a very serious situation, I mean, there’s a reason you take a gun to school,” said Police Captain Jack McGinnis.

McGinnis also said they are tracking the gun. So far he says it is not reported stolen, and is not registered in Pennsylvania.

Philadelphia School District officials are glad security worked and prevented this dangerous weapon from entering what’s supposed to be a safe haven for students, but says the situation is disconcerting.

“School Police have done a tremendous job capturing weapons at the door,” said School District Spokesman Fernando Gallard, “Now we need to look at why are students carrying these weapons, and why are they so easily accessible to young people?”

There were no reports of any injuries and classes were not disrupted.

The incident remains under investigation.

Read the KYW Regional Affairs Council special report, “Class Action: Making Schools Safe”

MORE NEWS: Hundreds Rally For Abortion Rights In Philadelphia With Democratic Gov. Nominee Josh Shapiro, Planned Parenthood