INDIO, Calif. -

A former Indian Wells elementary school teacher accused of molesting eight children was ordered Wednesday to stand trial.  

Riverside County Superior Court Judge Richard A. Erwood found that there was enough evidence for Robert Keith Bryan to stand trial on 17 criminal counts following a preliminary hearing at Indio's Larson Justice Center. Bryan, 60, is charged with 12 felony counts of committing a lewd act with a child and five misdemeanor counts of molesting a child. He is due back in court on Nov. 13.

The defendant, who taught fourth-graders at Gerald Ford Elementary School, was arrested in August 2012 at his Palm Desert home and released from jail the following day after posting a $220,000 bond.

According to a statement of probable cause -- prepared by Riverside County Sheriff's Department Investigator Michael Gaunt and attached to a request for a search warrant -- a 10-year-old girl alleged that Bryan touched her vagina over her clothes while she was in his classroom during the 2011-2012 school year.

Seven of Bryan's female students told authorities that he ``touched their bodies in a manner that made them feel `uncomfortable' or `weird,''' such as patting them on the buttocks and stomachs or rubbing their lower backs, Gaunt wrote.

Bryan had a history of allegations of inappropriate conduct dating back years, according to Gaunt. The educator was suspected of committing a lewd act in 1992 but wasn't charged because of a lack of evidence, the investigator wrote.

In 1994, Bryan was suspended from the school district without pay for inappropriately rubbing a female student's back, according to the investigator. 

In a memorandum, a principal told Bryan he had to stop touching students and not be alone with one or a few or he might face disciplinary action, according to Gaunt's declaration.

When authorities served a search warrant at Bryan's classroom in July 2012, they found a photo of a topless girl that had been downloaded four times on his computer and several other ``suggestive'' images of girls, Gaunt wrote. 

The computer contained ``several thousand'' images of children, with a ratio of 15 females to one male, according to Gaunt.

Students in Bryan's class during the past school year claimed he took ``numerous'' photos and videos of them during school hours, according to Gaunt's statement.

Paul Wallin, Bryan's attorney at the time, said a few days after Bryan's arrest that Bryan ``vehemently''  denied the allegations.

``He has been an outstanding educator for over 30 years,'' the Tustin-based defense attorney said. ``Mr. Bryan has never been convicted of any criminal offense in his entire life, and has been a local homeowner for 26 years. He has taught thousands of students over these almost three decades.''

Bryan started working for the Desert Sands Unified School District in 1986, Wallin said. He retired from the district in August 2012 for ``personal'' reasons, according to a school board agenda.

In January, Bryan was sued for unspecified damages on behalf of two of his students for allegedly sexually assaulting the students. The school district and Gerald Ford's principal were also sued for allegedly letting a teacher ``known to engage in inappropriate touching and other lewd conduct, to continue teaching and remain unsupervised with young female students,'' according to the complaint.

The firm of prominent Los Angeles attorney Mark Geragos is representing the students through their guardians. There is a hearing scheduled in the case on Nov. 20, according to court records.