A 13-year-old Texas boy jailed for five days for writing a story in which classmates are shot was abruptly released today with no charges pressed against him, his lawyer said.

"This has been a nightmare experience and it is a mystery to everyone," the boy's Dallas attorney, William Short, said.

The student was arrested at school Thursday and jailed since then on a charge of "making terroristic threats" by writing the story for a homework assignment.

The boy's mother said all her son had done was complete a legitimate classroom assignment to write a Halloween horror story--for which he received an "A."

But school officials decided the boy's story was so disturbing that they notified county juvenile authorities. He was then arrested and held on charges of making threats, said Byron Welch, the school superintendent in Ponder, a town about 50 miles northwest of Dallas,

"Let's face it. We live in a time when there are a lot of worries about safety and security in schools," Welch said.

A string of school shootings and plots of violence has prompted schools nationwide to adopt "zero tolerance" policies toward student violence.

The boy had been scheduled to have a first release hearing Wednesday. But he was released from the Denton County juvenile jail after a wave of local media attention.

An official at the Denton County district attorney's office confirmed that all charges against the boy had been dropped but declined to comment further.

"That means this child was in jail for six days for nothing. All of his constitutional rights were violated," Short said.

In the boy's story, his classmates are killed with a shotgun and a 9mm handgun but come back to life at the end, his mother, Jan Beamon, said on local radio.

The boy read his story to the class after the teacher offered extra credit for reading out loud. Some of the classmates named later complained to their parents, who in turn contacted the school.

On Thursday, school officials reviewed the story and decided to alert county juvenile authorities, partly because the boy has a disciplinary record, Welch said.

Short disputed the report of serious disciplinary problems, saying the boy had only been called down to the school office for being late and for talking in class.