Two Israel Defense Forces soldiers were sent to military prison for posting a video of soldiers dancing around a cannon on YouTube. Their humorous short clip received a more positive response, however, on the World Wide Web.

The 411th artillery battalion commander took a hard line in an effort to stamp out the practice of soldiers posting videos of themselves on the Internet.

Get The Times of Israel's Daily Edition by email and never miss our top stories Free Sign Up

The soldier who produced the video, in which his comrades-in-arms perform a version of the Harlem Shake, was sentenced to 14 days in prison and his commanding officer, who approved the lark, was sentenced to 21 days behind bars and stripped of his command.

The video clip received a generally positive response online not least because it showed IDF soldiers as being more human than the manner in which they often appear in the media, a Maariv report said Sunday.

Soldiers from the battalion who appeared in the video clip said they were surprised at the harsh response, in particular because they were careful to notify their commanders of the project and to get approval that the final product, free of any military sensitive material, could safely be posted online.

In the age of mobile phones with cameras and Internet social media there has been a rash of video clips posted online featuring IDF soldiers engaged in activities that are frowned on as unbecoming of the military. In 2010, six IDF soldiers got heat from their commanders for filming a video on patrol of them dancing to Ke$ha’s “Tik Tok.”

“In incidents in which pictures that are opposed to the values of the IDF are uploaded to the Internet, the soldiers involved are dealt with at the command level,” the IDF said in a response to the court-martial sentences. “Likewise, there are efforts made to try to reduce these kind of incidents. In the specific case, the soldier and officer involved were tried and punished.”