After debating for more than six hours, the House passed a bill legalizing the medical use of marijuana Wednesday night in a 96-51 vote, sending the bill to the Senate for approval.

The legislation would allow licensed pharmacists to dispense marijuana to patients with certain debilitating illnesses like glaucoma, cancer, HIV, Parkinson’s disease, or post traumatic stress disorder. In order to be eligible, patients would have to get a recommendation from a doctor.

Another medical marijuana bill passed both chambers of the legislature in 2007, but was vetoed by Gov. M. Jodi Rell.

In past years, medical marijuana supporter Rep. Penny Bacchiochi, R-Somers, has spoken of her late husband, who died of bone cancer. After trying the available medications, he found relief with marijuana.

This year, Bacchiochi focused on moving stories she heard during the bill’s public hearing, like a former lobbyist, stricken with Parkinson’s disease, who told the committee that cannabis allows him to feel a sense of normalcy.

But she said it was the testimony of young woman that she will never forget despite hearing thousands of stories for the past 10 years. Stricken with several illnesses, the woman was prescribed a Fentanyl patch, which is a medication more potent than heroin.

“This young woman was bedridden. She lost her hair. She drooled. She could not eat. She could not function,” Bacchiochi said. “She realized that the prescription medication she was taking was killing her. She detoxed off the legal medication she was taking and started using medical marijuana.”

After switching to the illegal substance, the woman gained her life back, Bacchiochi said. So much so, that her young son cried at the thought of his mother going back to the prescription meds, she said.

Bacchiochi said she understood the legal concerns of those opposed to the bill, but said it was important to consider the good it would do.

“Some of you will vote with your head. I respect it, I get it. In some ways I’m envious. Some of us vote with our heart. That’s no easier, believe me,” she said, adding she knew a vote against the bill didn’t indicate a lack of compassion. “. . . I’m just saying to you, Mr. Speaker and to the chamber, I will be voting with my heart.”

Opponents voiced concerns that the bill puts the state in direct conflict with federal law. The federal government considers marijuana to be a Schedule I controlled substance, with the most stringent regulations, but the bill requires the Consumer Protection commissioner to reclassify the substance as Schedule II.

Rep. Arthur O’Neill, R-Southbury, pointed to a letter from Connecticut U.S. Attorney David Fein saying the bill creates a “licensing scheme” that authorizes conduct contrary to federal law. The letter is similar to other indications from the federal government, he said.

“Any reasonable readings of these letters say . . . if you pass this law, we will be able to prosecute you,” O’Neill said.

When other states have received similar indications from the federal government, they stopped the process of legalizing medical marijuana, O’Neill said.

Because the bill requires marijuana producers to pay a $25,000 license application fee, O’Neill said it was unlikely they would be growing small amounts of the substance. Rather, they would probably be growing it in industrial quantities, which may attract the federal government’s attention, he said.

Rep. Gerald Fox, who co-chairs the Judiciary Committee, said other states have felt comfortable passing medical marijuana laws after receiving similar letters from U.S. Attorneys.

“The U.S. Attorney has not relinquished any of their powers. That’s what the letter says,” Fox said. “But letter also says on the first page that pursuing these individuals is not their first priority given their limited resources.”

However, Rep. Brian Becker, D-West Hartford, said the state should ask Congress to address the issue, not pass legislation to legalize it. It was within the state’s power to decriminalize marijuana, but not allow its use.

“Even if we passed this bill today our citizens will still be subject to arrest by federal agents and there’s nothing we can do to prevent that,” he said.

Rep. John Hetherington, R-New Canaan, said passing a bill that does away with all of Connecticut’s marijuana restrictions would be more legal than passing legislation expressly allowing it for some people.

House Minority Leader Larry Cafero said his biggest concern was the potential abuse of the system, specifically by minors. Cafero, a school expulsion officer in Norwalk, said the number of cases he has seen involving youth using marijuana “have gone through the roof” since the legislature passed a bill decriminalizing small amounts last year.

“The actions we take in this chamber have a very real effect, sometimes good sometimes bad, on the world out there,” Cafero said. “Now we’re going to open up a whole other area of using marijuana, one that hasn’t been proven.”

Rep. Rob Sampson, R-Wolcott, said people shouldn’t interpret votes in support of the bill as an indication that young people should think it’s acceptable to smoke marijuana. If a teenager wants to form an opinion on the substance, they can already look to states like California that have allowed it under a less restrictive program, he said.

Sampson said the bill goes a long way toward “truly treating marijuana as a medicine.” He said he opposed last year’s bill because it was too loosely written, but this year the bill allows doctors to decide whether to prescribe it and requires pharmacists to dispense it

“Outside of that I don’t think I can control the perception of anyone else,” he said.

Bacchiochi agreed, saying for every study that exists suggesting marijuana is a gateway drug, another finds that it is isn’t.

“This is not the gateway drug. This is not what is going to send children down the path to drug destruction,” she said.