PHOENIX (AP) -- The husband of former U.S. Rep. Gabrielle Giffords generated nearly 4,000 comments on Facebook from people on both sides of the gun debate after he posted a photo of himself buying a military-style rifle — a purchase he said he made to demonstrate how easy it is to obtain the kind of firearms he's lobbying Congress to ban.

A background check took only a matter of minutes to complete, Mark Kelly said in the Facebook post, adding that it's scary to think people can buy similar guns without background checks at gun shows or on the Internet.

It didn't take long for gun-rights supporters to accuse Kelly of being a hypocrite for buying an AR-15-style rifle and a 45.-caliber handgun. Many of the Facebook comments focused on his motivations and the rules for purchasing such guns.

Kelly and Giffords started a gun control advocacy group, Americans for Responsible Solutions, amid the wave of recent mass shootings. They have been touring the country in recent months in support of expanded background checks for gun purchases.

Kelly bought the guns at a Tucson shop the day before he appeared with his wife at the supermarket where she was wounded during a shooting rampage that left six dead and 12 others wounded two years ago.

The public event last week was the first time the survivors had come together since the January 2011 shooting.

Giffords resigned from Congress last year as she continues to recover from her injuries.

The AR-15 is among 157 military-style weapons that would be banned under a bill pending before the U.S. Senate Judiciary Committee. Kelly, a former astronaut, said he intends to eventually hand in the rifle to Tucson police.

Doug MacKinlay is the owner of Diamondback Police Supply, the shop where Kelly bought the guns. He said Kelly bought the rifle on March 5 but couldn't immediately take possession of it because the shop had bought it from a customer. As a result, the store is required by a Tucson ordinance to hold the gun for 20 days to give the city enough time to make sure the weapon wasn't used in a crime, MacKinlay said.

MacKinlay said Kelly never revealed to the store's staff why he was buying the guns and added that it would be wrong to refuse to sell a gun to someone because of their personal views.

"He is a U.S. citizen, an Arizona citizen and expressing his Second Amendment right to purchase and own a firearm," MacKinlay said.

Todd Rathner, a lobbyist for the National Rifle Association's affiliate in Arizona and a national NRA board member, questioned the point that Kelly was trying to make in buying the guns, saying a model citizen such as Kelly should be able to buy a gun relatively quickly. He also noted that such a purchase could have been a good investment as the value of those types of weapon soars amid heightened demand from gun owners.

"If you believe him, it's a cheap publicity stunt," Rathner said. "If you don't, then he was speculating on the value of the rifle because he knew the prices would be inflated."

The advocacy group started by Giffords and Kelly had no immediate comment Tuesday on Kelly's gun buys.

But the group released a statement from Kelly on the Senate Judiciary Committee's approval Tuesday of a proposal to expand federal firearms background checks to nearly all gun purchases. Kelly said the 10-8 vote was a huge step in keeping guns out of the hands of criminals and mentally ill people. Kelly's statement didn't address the controversy over his own gun buys.

Kelly, a former astronaut who plans to keep the handgun, told CNN on Monday that it was important for him to have firsthand information on the ease of buying guns such as the AR-15 and that he looks forward to buying a firearm at a gun show in the future. Kelly and Giffords have long been supporters of gun rights and owned handguns themselves.