<div>
<img alt="example" src="\images\show.jpg" />
<img alt="exampleAll" src="\images\showAll.jpg" />
</div>
var src = $('img[alt="example"]').attr('src'); alert("source of image with alternate text = example - " + src); var srcAll = $('img[alt="exampleAll"]').attr('src'); alert("source of image with alternate text = exampleAll - " + srcAll );
No comments:
Post a Comment