I'd like to use my image tag
id="bla" src="....." in my web page by changing dynamically the
src parameter. I usually do that with a selector and setting the
src property, i.e.
but today I wanted to follow another way :
var bullet = $("#bla"); bullet.src = "/new/image/path.png";
I expected that code change my picture in my HTML page, but it doesn't happen.
The statement doesn't produce any error and if I watch my
bullet.src value I find the new path for the new picture.
If I query
$("#bla").prop("src") I find the old path, could somebody tell me what's wrong?