当我单击2 img not identique时,我希望将其更改为另一张img,但无法正常工作
function changeImage1()
{
var img1 =document.getElementById("image_change");
var img2 =document.getElementById("image_change1");
var img3 =document.getElementById("image_change2");
if(img1.src===img2.src)
{
setTimeout( function ( ) { alert( "identique" ); }, 1000 );
}
else if(img1.src === img3.src)
{
document.getElementById("image_change").src="img111.jpg";
document.getElementById("image_change2").src="img111.jpg";
setTimeout(changeImage1, 1000);
}
}