The Massachusetts Legislature has approved a new law intended to bypass the Electoral College system and ensure that the winner of the presidential election is determined by the national popular vote.

“What we are submitting is the idea that the president should be selected by the majority of people in the United States of America,” Senator James B. Eldridge, an Acton Democrat, said as he introduced the bill on the Senate floor.

Under the new bill, he said, “Every vote will be of the same weight across the country.”

But Senate minority leader Richard Tisei said the state was meddling with a system that was “tried and true” since the founding of the country.

“We’ve had a lot of bad ideas come through this chamber over the years, but this is going to be one of the worst ideas that has surfaced and actually garnered some support,” said Tisei, who is also the Republican candidate for lieutenant governor.

The bill, which passed the Senate on a 28-9 vote, now heads to Democratic Governor Deval Patrick’s desk. The governor has said in the past that he supports the bill, said governor’s spokeswoman Kim Haberlin.

Under the law, which was enacted by the House last week, all 12 of the state’s electoral votes would be awarded to the candidate who receives the most votes nationally.

Supporters are campaigning, state by state, to get such bills enacted. Once states accounting for a majority of the electoral votes (or 270 of 538) have enacted the laws, the candidate winning the most votes nationally would be assured a majority of Electoral College votes. That would hold true no matter how the other states vote and how their electoral votes are distributed.

Illinois, New Jersey, Hawaii, Maryland, and Washington have already approved the legislation, according to the National Popular Vote campaign’s website.

The current Electoral College system is confusing and causes presidential candidates to focus unduly on a handful of battleground states, supporters say. They also say that the popular vote winner has lost in four of the nation’s 56 elections.

Presidential candidates now “ignore wide swaths of the country” they consider strong blue or red states and focus their campaigning on contested states, Eldridge said. If the president were picked by national popular vote, he argued, candidates would spread their attention out more evenly.

“That’s really what we’re talking about is making sure that every voter, no matter where they live, that they’re being reached out to,” he said.

Opponents say the current system works. They also point to the disturbing scenario that Candidate X wins nationally, but Candidate Y has won in Massachusetts. In that case, all of the state’s 12 electoral votes would go to Candidate X, the candidate who was not supported by Massachusetts voters.

Tisei also criticized the proponents for not following the normal procedures to seek a constitutional amendment.

“The thing about this that bothers me the most is it’s so sneaky. This is the way that liberals do things a lot of times, very sneaky,” he said. “This is sort of an end run around the Constitution.”

The measure passed both branches of the Legislature in 2008 but did not make it all the way through the process.