I am trying to place an image inside a div.
function pleaseW(){
$('#info').html("Please wait ..."); //1 this works
$('#info').html("<img id='busy01' src='busy01.gif' />"); //2 doesn't work
$('#info').append("<img id='busy01' src='busy01.gif' />"); //3 doesn't work
$('#info').prepend("<img id='busy01' src='busy01.gif' />"); //4 doesn't work
}
The image called busy01.gif
is in the same folder as in the current file. The problem is that lines 2, 3, and 4 do not put an image in the div.
If I put the html directly into the page, the image shows. There has to be some unrelated problem going on with the page, as this Javascript/jQuery is perfectly valid.