The fluctuating temperatures...cold to warm to cold to warm, during their growing times causes the onion to prematurely bloom or bolt. From what I have read once the onion has 'bolted' and sent up a flower stalk the best thing to do is use the onion as soon as possible. The stalk growing through the middle of the onion makes storage for any length of time unlikely.
Yes, cut them off since setting seed will affect the bulb in a very bad way! Onion bulbs are just food storage containers, and setting seed drains the bulb of some taste and crispness. When our onions start to get little domes on a long, stiff, hollow stalk, I pull that one and it goes into the supper dish.
If you are planning on eating the onion...then I would also vote for reoving the flower; however, I usually leave a flower or two because I find them attractive and the butterflies and bees in my area flock to them.
Donna, I've never seen an onion bloom before, if it is not too late can you post a photo of it? Thanks
We also have a couple rows of onions about to bloom and mom always forces me to eat onion with everything. Good thing I like "green" onion.