If you live in Portland, you can’t buy fireworks at home, but you could buy them in Scarborough if you planned to use them in Westbrook or some other town that hasn’t banned them. You can keep them in Portland, however, unless you have the intent to use or sell them there, which is a violation of a new city ordinance.

We never liked the idea of the state ending its longtime ban of fireworks because in the hands of amateurs, they can cause fires and injuries. But the new law is even worse than we anticipated.

Even before next Fourth of July rolls around, Maine people will have to negotiate a crazy quilt of regulations that could differ from town to town, including some differences among towns that ban them.

Portland was the first to ban fireworks, and given the population density of some of its neighborhoods, it’s easy to see why the city’s government did not want to wait for something bad to happen. But it creates a bind for neighboring communities that may not want to pass a ban as encompassing as the one enacted by the state’s biggest city.

This is one area where regional cooperation would make sense. If the towns of greater Portland, for instance, could meet together and pass consistent ordinances, residents would be well served. That way they would not have to do town-by-town legal research and determine whether they are in compliance with local rules if they decide to take advantage of the new flexibility provided by the state.

The Legislature also could help. If repealing the recently passed fireworks law is a political dud, as we suppose it is, lawmakers could at least amend it and create a model ban that individual towns could opt into.

That way, any town that chose to outlaw fireworks could simply agree to accept the model ordinance. Every town that banned fireworks would have the same ban, and they could indicate their status with signs at the town borders, if they wanted. Residents and visitors would know where fireworks were legal and illegal and what the specific restrictions in the ban might be.

We thought continuing the statewide prohibition made sense, but if we are going to have this decided on a town-by-town basis, some consistency would be good. The Legislature should provide a way to make that easier.