I have a web page with a link called “Download”. When user press that link, I’m using javascript to add a gif animation so that user knows that the system is busy. Here is the code:
function submit_form()
{
var nfy = document.getElementById('nfy_area');
var img = document.createElement( 'img' );
img.setAttribute('src', 'images/wait24trans.gif');
nfy.innerHTML = "This will take a few minutes. Please be patient...";
nfy.appendChild( img );
document.forms["download_form"].submit();
}
However, this only works for Opera. For Chrome, nothing is displayed. For Firefox, a broken image is displayed.
Why?
Thanks,
SOLVED: The target of the submit action is another page. So presumably both FF and Chrome detect this and stops loading anything else on the current page. I put in a delay before submitting the form and now it works fine.
Commendably, Opera works perfectly well.