Ver Mensaje Individual
  #13 (permalink)  
Antiguo 16/04/2009, 13:16
msdwh
 
Fecha de Ingreso: diciembre-2004
Mensajes: 96
Antigüedad: 19 años, 4 meses
Puntos: 0
Respuesta: Mostrar una barra de progreso mientras se cargan los datos

hola amigo si aun sigues con el problema te comento esta solucion

Código PHP:
<html>
<
head
<
script type="text/javascript">

ajax = function()
{
  var 
objetoAjax=false;
  try {
       
objetoAjax = new ActiveXObject('Msxml2.XMLHTTP');
       }
  catch (
e)
  {
    try {
        
objetoAjax = new ActiveXObject('Microsoft.XMLHTTP');
        }
    catch (
E
    {
        
objetoAjax false;
    }
  }

    if (!
objetoAjax && typeof XMLHttpRequest != 'undefined'
    {
           
objetoAjax = new XMLHttpRequest();
    }
     return 
objetoAjax;
}



 function 
load()
{  
   var 
ajax ajax();   
   var 
divContenedor =  document.getElementById("load");
   var 
divContenedorDatos =  document.getElementById("data");

    
ajax.open("GET","php que genera los datos (por ejemplo)");                                    
    
   
ajax.onreadystatechange = function()    
   {       
     if(
ajax.readyState <= 3)
      {
         
divContenedor.style.display 'block';  
      }

     if(
ajax.readyState == 4)        
     {
         
divContenedorDatos.innerHTML ajax.responseText//resposta del server con los datos             
         
divContenedor.style.display 'none'

       
}    
   }
ajax.send(null);


window.onload = function() 
{
      
load();
}
</script>
</head>
<body>
<div id="load" style="display:none;position:absolute;top:0;bottom:0%;left:0;right:0%;z-index:99;height:300px;width:300px;background-image:url(../images/ajax-loader.gif);"></div>
<div id="data" style="width: 300px; height: 300px; float: left;"></div>
</body>
</html> 

en la etiqueta background-image:url() pasale el nombre de la imagen que sera tu preload y listo debe de funcionarte sin problemas cualquier cosa avisame y con gusto te ayudaremos


Saludos