Beyond the boom of Israeli airstrikes and the stream of rockets fired from Gaza, Israel and Hamas are also battling to control the message emanating from this latest Israeli-Palestinian conflagration.

Using videos, Twitter, text messages, leaflets and phone calls, both sides have attempted to direct the tone of the fighting — for their own public, their opponent's population and for a global audience. Propaganda and psychological warfare are nothing new in battle, but technology and social media have exponentially increased the ability of each side to penetrate their intended audiences.

Each side has sought to tip the moral scale in its favor with an international audience. Israel has tried to make its case that it is defending its citizens from unprovoked attacks but taking steps to avoid killing civilians on the other side. Hamas has appealed to the world by pointing to the high civilian death toll from Israel's onslaught on Gaza.

Israel and Hamas are each addressing the other's populations as well.

Israel has pushed the message to Palestinians in Gaza that the territory's Hamas rulers are to blame for the bloodshed that's being wreaked. In phone calls that the military makes to Gazans to tell them to evacuate their homes before a strike, the recorded script in Arabic also tells them that Hamas is using them as human shields.

Hamas, in turn, has sent text messages directly to Israelis, warning them that the group will continue firing rockets at them until its demands — like the end of the long-stifling blockade of the tiny Gaza Strip — are met.

"This is a war over public opinion," said Yuval Dror, an expert in digital communications. "It's an inseparable part of battle in the modern age."

Israel launched the war on July 8 in response to heavy rocket fire out of Hamas-controlled Gaza. More than 600 Palestinians and 29 Israelis have been killed in the fighting, which escalated last week with the start of a ground offensive. The war over hearts and minds that has accompanied it has been just as dramatic.

Israel's military has been at the forefront of trying to mold the message. Its spokesperson's office has posted more than 40 videos online since the conflict began, an onslaught of footage aimed at portraying its citizens as under threat from Hamas attacks.

The videos range from raw footage taken from a warplane's cockpit, to high-gloss productions with jazzy graphics. The other main theme in them aims to show Israel is trying not to hit civilians but Hamas is putting them in danger. One picture posted on the military's Twitter feed was a schematic drawing purporting to demonstrate how Hamas tunnels are built intentionally underneath Gazan homes.

In the most sensational offering, Israel released video game-like footage of what the military says is an attempt by Hamas militants to swim from Gaza to Israel to infiltrate and carry out attacks. The video, which has garnered more than a million views on YouTube, shows the suspected militants creeping onto the beach, scampering on sand dunes, and then one by one getting picked off by blasts of Israeli fire. The military says four militants were killed in the incident.

The message was that Hamas is not just relying on rudimentary rockets but is actively trying to attack inside Israel.

Hamas quickly countered with its own video, presenting the same message from the other side — apparently trying to intimidate Israelis and show its own population it is striking back against the Israeli pounding of Gaza. Its video, with a suspenseful musical score, shows Hamas navy commandos training. Armed men in full scuba gear are seen weaving through murky green waters, emerging at the water's surface and opening fire.

In other videos, Hamas has sought to boast about its capabilities. Its videos have shown compilations of rockets whizzing toward Israel. Some of its videos are in Hebrew, aiming to intimidate Israelis.

Hamas has sent Israelis personal text messages, warning that they will continue to strike until its conditions for a cease-fire are met, and boasting that "we have forced you to hide in shelters like mice." Hamas warned Israelis on its web site that it would strike Tel Aviv at precisely 9 p.m. in the early days of the fighting. In the end, Tel Avivis fled toward shelters when the sirens went off several minutes past nine and three rockets were intercepted over the city by the Iron Dome missile defense system.

Hamas claims its media campaign has helped unify Gazans behind it and stoke protests against Israel in cities around the world. "We were able to confront their media machine and to win the battle in most cases," said Mushir al-Masri, a Hamas spokesman.

But there are limits to the effect of media campaigns. There's little sign that Israel's efforts to turn Gazans against Hamas have had any success, with Palestinians unsurprisingly blaming Israel for the shelling demolishing homes, sometimes killing entire families, in pursuit of a Hamas militant target.

Israelis, meanwhile, hardly seem intimidated by Hamas into pushing for an end to the Israeli campaign against the group. Hamas messages in Hebrew have become the butt of Israeli jokes on line, with one Israeli offering grammar tips for a Hebrew tweet on the feed of Hamas' military wing.

And despite attempts to sway world opinion, Israelis know that continuing images of dead civilians will undermine support.

"Public opinion has a certain patience limit," said Avital Leibovich, a former Israeli military spokeswoman. "There is a certain point where legitimacy begins to be undermined by difficult images."


Associated Press writer Ibrahim Barzak contributed to this report from Gaza City, Gaza Strip.