Ver Mensaje Individual
  #1 (permalink)  
Antiguo 22/04/2010, 19:30
birdaleja
 
Fecha de Ingreso: junio-2009
Ubicación: mexico
Mensajes: 106
Antigüedad: 14 años, 11 meses
Puntos: 0
Exclamación AS3 Problema con precarga en servidor error "Infinity"

Hola, quizas alguien me pueda ayudar a resolver este problemita....

tengo un sitio hecho en flash cs4/as3 y necesita flash player 10.
basicamente son solo 2 swf y 1 xml.

1swf es el precargador, que carga al 2swf.
2swf es el contenido, que carga al xml.
1 xml que brinda informacion solo al 2swf.

Este sitio lo tuve bastante tiempo en un servidor pago sin problemas pero ahorita lo cambie para otro servidor tambien pago y tiene problemas con el cargador. En lugar de cargar los numeritos que van mostrando el porcentaje ahora solo carga el valor "Infinity".

Para verificar que no fueran errores de mi codigo subi el sitio a un servidor gratuito y resluta que funciona perfecto?! Contacte a los que me proveen el servicio de hospedaje y dicen que no encontraron ningun problema de configuracion ni nada.

servidor pago: coloresladob.com
servidor gratuito: coloresladob.webcindario.com

Aqui esta el codigo de mi cargador, bueno parte de el:

Código:
package 
{
	import flash.display.*;
	import flash.events.*;
	import flash.net.URLRequest;
	
	import gs.*;
	import gs.easing.*;

	public class cargador extends MovieClip
	{
		private var l:Loader = new Loader();
		private var url:String = "inicio.swf";
			
		public function cargador()
		{
			addEventListener(Event.ADDED_TO_STAGE, iniciar);
		}
		
		private function iniciar(e:Event):void
		{
			setInicio();
		}
		
		private function setInicio():void
		{
			l.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, loop);
			l.contentLoaderInfo.addEventListener(Event.COMPLETE, completo);

			if(stage.loaderInfo.url.substr(0,4) != "file"){
				var d:Date = new Date();
				url += "?cachebuster=" + d.getTime();
				}
			l.load(new URLRequest(url));
		}
		
		private function loop(e:ProgressEvent):void
		{
			var porc:Number = e.bytesLoaded / e.bytesTotal;
			var num:Number = (99- Math.ceil(porc*99));
			
			if (num < 10)
				txts.porcentaje.text = "0"+String(num);
			
			if (num >= 10)
				txts.porcentaje.text = String(num);
		}
		
		private function completo(e:Event):void
		{	
			removeEventListener(Event.ADDED_TO_STAGE, iniciar);
			l.contentLoaderInfo.removeEventListener(ProgressEvent.PROGRESS, loop);
	
			for ( var i:int = 0; i< this.numChildren; i++)
			{
				this.removeChildAt(i);
			}
			addChild(l);	
		}
	}
}
muchas gracias