Under Armour is waving the white flag.

The athletic apparel maker is apologizing for a t-shirt that invokes a crucial World War II battle in which thousands of Marines were killed.

The $24.99 shirt, dubbed "Band of Ballers," depicts basketball players raising a hoop in the style of a famous photograph of Marines lifting an American flag during the battle of Iwo Jima 70 years ago.

"We deeply regret and apologize that a t-shirt that was not reflective of our values in honoring and supporting our country's heroes went on sale," the company said in a statement Saturday.

Under Armour said it was removing the shirt from store shelves and would take steps to "ensure this doesn't happen again."

The shirt was seen as offensive by members of the military and their supporters, according to comments posted on Under Armour's (UA) Facebook (FB) page and on Twitter (TWTR).

Related: Under Armour earnings are a slam dunk

"Stupid, stupid move Under Armour. You've offended the most amazing fighting force on the face of the earth and they don't forget or forgive easily," one comment reads.

While some commenters rejected the apology, others praised Under Armour for admitting its mistake and noted that the company has been a big supporter of veterans.

"I am a Marine Vet and still a customer. Thanks for doing the right thing UA. Time to Move on," another comment reads.