No, you don't need to check both values. One is enough.
$POST["submit_x"] & $POST["submit_y"] are the coordinate
(x,y) in pixels, of the click inside the image. If one of them is <> 0, then it means that the user has click inside the image.
Plus you can't have two differents buttons with the same
name (here "submit")
<?
if ($POST['submit1_X'] >0)
{
// here the user has clicked on the submit1 image/button
}
elseif ($POST['submit2_x'] >0)
{
// here the user has clicked on the submit2 image/button
}
else
{
?>
<form action = <?$PHP_SELF?> method = post>
<input type="hidden" name="something" value="Value">
<input type="image" name="submit1" src="./images/image.gif">
<input type="image" name="submit2" src="./images/image2.gif">
</form>
<?
}
?>
Hervé.