The CEO of a 100-year old Montana ice cream maker has offered to resign after he made what was perceived to be a racist remark on the company's Facebook wall.

The brouhaha began when a self-identified Muslim customer asked on the Facebook page if the Wilcoxson Ice Cream contained pork in the gelatin used to make it.

“We don't deliver outside of Montana, certainly not Pakistan,” CEO Matt Shaeffer wrote back.

The customer replied that the comment was “rude” for assuming he lived in Pakistan. Underneath the customer's name on Facebook it says that he lives in Sheridan, Wyo., an area to which the wholesale ice cream maker does deliver.

Shaeffer told NBC News he is sorry for what happened. “It was never intended to offend,” he said.

“I was wrong,” said Shaeffer, whose company, in addition to local customers, has supplied ice cream to Yellowstone National Park since the 1920's. “I should have just answered the question.... I don't want to be the one who took down a 100-year old company because I made a stupid comment. If necessary, I will resign.”

The whole dust-up appears to be a case of mistaken assumptions and late-night Facebooking gone horribly wrong, Shaeffer believes.

A screenshot of the Facebook conversation was posted on popular link-sharing website Reddit and soon made the rounds on news websites, blogs, and forums. Users flooded the company's Yelp page with one-star reviews and angry comments, driving down its Yelp rating. The company's Facebook page is down now too, taken offline by Shaeffer because of nasty remarks and coarse language in the comments.

The internet outrage centers on the belief that Shaeffer intentionally made a racist joke. But he told NBC News that before responding, he clicked on the user's Facebook profile and saw under the “Map” box a recent ping showing a location in Pakistan.

That feature usually indicates the geographic location of recent updates made by the Facebook user. Responding to the comment at 10 p.m. after a long day of work, Shaeffer said he mistakenly assumed the customer was from Pakistan.

By 4:30 a.m. the next morning, the company's Facebook page had already filled with hundreds of “derogatory” and “nasty” messages. Now after several days of bouncing around the Internet, the rage bandwagon hasn't shown any signs of stopping.

“It's a mistake to view this as an online-only problem,” said James Alexander, founder and CEO of Vizibility, a New York-based online reputation management startup. He said this has the potential to “jump out of Facebook to become a full-blown crisis.”

Alexander told NBC News he questioned Wilcoxson's choice to take down the Facebook wall. He noted that Facebook has several tools for managing comments on your company Facebook page, like manually deleting inappropriate comments, changing settings to filter out comments with foul language or hate messages, or even even turning off comments and posting a message saying you're disabling comments until the conversation cools off.

He recommended that the company post a full statement online to apologize, explain itself, and make things right. But the key thing is to communicate.

“To withdraw from a conversation that's about you really requires some hard-thinking,” said Alexander. Just because you take down the Facebook wall, “doesn't mean there isn't a hashtag” about your company on Twitter.

Lost in the mix is the answer to the original question. Wilcoxson's ice cream contains only Kosher gelatin, which doesn't use any pork products.

More money and business news:

Follow NBCNews.com business on Twitter and Facebook