tags:

views:

29

answers:

1

I'm opening new tab by click on button in the home page , and building the new tab from copying some Elements from the home page,on loading event,i do all my work , also I'm changing image src on load event by filling it from the server , i don't know why fire fox stuck on status of "Transferring data from server",can any one help me in this problem?

this is piece of my code:

window.onload = function () {
 document.getElementById('demo_tab_info').innerHTML=opener.document.getElementById('demo_tab_ifo').innerHTML;
 if(document.getElementById("Have_Patient__Photo_image" ).value =='true')
 {
      document.getElementById("pat_<%=Pat_Acct%>_pic_area").innerHTML="<img name='pat_<%=Pat_Acct%>_pic_image' id='pat_<%=Pat_Acct%>_pic_image' src='' onload=\"Fix_Dimensions('pat_<%=Pat_Acct%>_pic')\"/>";
      var Image_Element_Name        = 'pat_<%=Pat_Acct%>_pic_image';
      var Image = document.getElementById(Image_Element_Name);
      Image.src='/jspapps/apps/file_uploader/view_image.jsp?table=pat_dri_images&db=admin&im_type=pat_pic&pat_acc=<%=Pat_Acct%>&ts='+(new Date()).getTime();      
  }
}
+2  A: 

Install Firebug and use the "Net" tab to see which connections are made and which one is kept open.

Aaron Digulla
i install it but i could not know how i can see the connections,can you explain more?
ama
Sure :-) Open Firebug by clicking on the little icon in the bottom border. Click on "Net". Click on the little arrow next to "Net" and select "Enable". Reload the page.
Aaron Digulla
thnx :) ,but i follow exactly your instructions but i got ,0 URL with 0 kb ,and still firefox stuck at "transferring data from server"
ama
Odd. You should see the URL which you apply to `Image.src` but my guess is that the URL is broken. Do you see the correct image? If not, try `<%=request.getContextPath() %>` instead of `/jspapps`.
Aaron Digulla
yes i see the right images,i loaded 3 images , 2 of them loaded quickly and the fire fox status goes to "Done" ,after that it begin to load the third images with "Done" status ,after viewing it ,fire fox goes to status of "transferring data from server"
ama
Sounds like a bug. Which version of Firefox? What happens if you click "Stop"?
Aaron Digulla