Bit of a controversy surrounding a 12 year old student in Maryland who refused to stand for the Pledge of Allegiance.
Fortunately, the U.S. Supreme Court resolved this issue more than half a century ago:
If there is any fixed star in our constitutional constellation, it is that no official, high or petty, can prescribe what shall be orthodox in politics, nationalism, religion, or other matters of opinion, or force citizens to confess by word or act their faith therein. If there are any circumstances which permit an exception, they do not now occur to us.
We think the action of the local authorities in compelling the flag salute and pledge transcends constitutional limitations on their power, and invades the sphere of intellect and spirit which it is the purpose of the First Amendment to our Constitution to reserve from all official control.