They aren't allowed. There are several very good reasons that cellphones are not meant to be brought into the classroom.
First, students can be easily distracted by texting on their phone instead of listening to a lesson. Texting in class is just as annoying and disrespectful as passing notes. Texting means that at least one student is not paying attention in that room. A good lesson should be like a conversation, so texting during class is like texting while you're chatting someone. It tells the teacher and other students that your time is more valuable than theirs and you don't much care what anyone in the room has to say. It's just plain rude.
Second, cellphones can easily be used to cheat on a test. Students can text their friends across the room or even in another class for answers to a test or quiz. Creating this network of answer sharing defeats the purposes of having an assessment and is incredibly unfair to anyone not in on the cheating. Of course, cheating really only hurts the cheaters in the long run as they are the ones who are missing out on valuable skills and knowledge.
Finally, texting can increase bullying in a school. Bullies are already sneaky and bullied kids are already scared. Remove the verbal aspect and catching the bullying becomes a lot harder. Students who are the victims of bullying over cellphones and the internet can be driven to suicide. I believe on of the reasons is because the responsibility is entirely on them to tell someone about the bullying instead of someone being able to hear or see the bullying in person.
Despite these very good reasons, students text in class. They get their phones out and do what they can whenever they can. What's worse is that there are parents that seem to find this behavior completely acceptable. I've had to call parents about cellphone use in class and heard "Well, he was texting me, so you can't take his phone!" Ma'am, why are you texting your child when they are in school? Barring a family emergency, which shouldn't be read over a text message anyway, there's no reason to communicate with your school aged child via text message during school hours. "Well, was he done with his work?" Even if he was, completing work does not grant one electronic privileges that can still result in cheating and bullying. If I allowed any student who finished to whip out their cellphone, students would get lazy with their work and "finish" just to play.
It's because of these reasons that all cellphones really need to be turned off during the school day. If your child doesn't adhere to that rule, then they shouldn't have a phone. It's as simple as that. They can cry and complain all they want, but not behaving properly with a device means they don't get to have it.