Read more about this story from CNN affiliate KGTV.
(CNN) -- A gunman faces six counts of attempted murder and other charges after he opened fire at an elementary school in southern California and injured two students who were outside during lunch, authorities said.
The girls, ages 6 and 7, suffered minor arm injuries in the shooting Friday in Carlsbad, said Lt. Jay Eppel of the Carlsbad Police Department.
Both were flown to Rady Children's Hospital in San Diego. Police indicated the students each were grazed in the arm by bullets.
Construction workers at Kelly Elementary School detained a suspected identified as Brendan L. O'Rourke, 41, shortly after noon until officers arrived, Eppel said. Police do not suspect the man has a relationship with any students at the school.
Worker Carlos Partida got into his truck and was able to knock the gunman down with the vehicle, police said in a statement. The man, dressed in black, was then tackled by other construction workers and witnesses. O'Rourke appeared to be trying to reload his handgun, police said, adding that the workers managed to remove the weapon.
The suspect's vehicle was parked near the school. Officers found a handgun and propane tank inside, police said. O'Rourke also had taken a small gas can to the playground, police said.
The suspect was taken to a hospital after he complained of back and neck pain, and faces six counts of attempted murder and numerous weapons violations, according to the statement.
Police said the suspect provided three names, one of them a woman's name, when asked for identification.
The superintendent for the school district thanked good Samaritans, police and school staff members for their actions Friday.
Counselors will be at the school Monday to help students, staff and families "handle the anxiety and fear that can result from a traumatic experience," John A. Roach said in a statement Saturday.
Third-grade student Shaylyn Foley was on the playground with her friend and told CNN affiliate KGTV what she saw.
"I saw him and he was across the street. Phoebe said, 'Who is he?' Then I'm like, 'Phoebe, he might not be a good man.' Then he put his hand out and then I heard the shot, and then I'm like, 'Phoebe, come on, this isn't OK.'"
Shaylyn and her friend ran away as the gunman fired.
Students were taken to a local park to be picked up by their parents.
Pete Anderson, who operates a small research vineyard near the school, said he was tending vines when "I heard something like a gunshot, followed by another."
Three more shots followed about 30 seconds later, he said.
Children were yelling as they ran from a playground back toward the school, Anderson said.
"At this point, I knew this was not a drill," he told CNN.
Anderson said he did not see the accused shooter until after he was taken into custody.
The school is in a residential neighborhood in this city between Los Angeles and San Diego.
"This is extremely unusual," Anderson said.
CNN's Phil Gast contributed to this report.