Updated, 12:09 p.m. ET.

Texas lawmakers are one step closer to sending a controversial abortion bill to the desk of Governor Rick Perry.

The Texas House voted on Wednesday, 96-49, to pass House Bill 2, which would ban abortions after 20 weeks of pregnancy, require abortions be performed in ambulatory surgical centers, require doctors performing abortions to have admitting privileges at hospitals within 30 miles of the facility, and require doctors to administer abortion-inducing drugs in person—rather than allow a woman to take it at home.

The House had tentatively passed the bill Tuesday night after an all-day debate as onlookers clad in blue, in support of HB2, and in orange, in opposition of the bill, flooded the gallery to watch the procedure.

A House committee approved HB2 last Wednesday after hours of public testimony.

The abortion bill gained a second life after Perry announced a second special session at the end of June to vote on the issue. The bill failed to gain enough votes during the Texas legislature’s regular session (which required a two-thirds majority), and it also failed in the last special session after an epic filibuster in the Senate by State Sen. Wendy Davis, which brought national attention to the measure.

The bill now moves to the Senate.