It's the law:Texas Education Code § 25.082. School Day;  Pledges of Allegiance;  Minute of Silence(a) A school day shall be at least seven hours each day, including intermissions and recesses.
(b) The board of trustees of each school district and the governing
board of each open-enrollment charter school shall require students,
once during each school day at each campus, to recite:
(1) the pledge of allegiance to the United States flag in accordance with 4 U.S.C. Section 4;  and
(2) the pledge of allegiance to the state flag in accordance with Subchapter C, Chapter 3100, Government Code.That being said a student may opt out:
(c) On written request from a student's parent or guardian, a
school district or open-enrollment charter school shall excuse the
student from reciting a pledge of allegiance under Subsection (b).
(d) The board of trustees of each school district and the governing
board of each open-enrollment charter school shall provide for the
observance of one minute of silence at each campus following the
recitation of the pledges of allegiance to the United States and Texas
flags under Subsection (b).  During the one-minute period, each student
may, as the student chooses, reflect, pray, meditate, or engage in any
other silent activity that is not likely to interfere with or distract
another student.  Each teacher or other school employee in charge of
students during that period shall ensure that each of those students
remains silent and does not act in a manner that is likely to interfere
with or distract another student.
4951