       poster.contentLoaderInfo.addEventListener(Event.COMPLETE, function(): void {
         posterContainer.addChild(poster);
       });
-      poster.load(new URLRequest(url));
+
+      poster.load(new URLRequest(posterUrl));
     }
 
-    private function loadVideo(url: String): void {
+    private function loadVideo(): void {
       connection = new NetConnection();
       connection.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
       connection.connect(null);

  import flash.display.StageAlign;
  import flash.display.StageScaleMode;
  import flash.events.Event;
  import flash.media.Video;
  import flash.text.TextField;
  import flash.net.NetConnection;
  import flash.net.NetStream;
  import flash.net.URLRequest;
  import flash.events.NetStatusEvent;

  public class Player extends Sprite {

    private var position: uint = 0;

    private var posterContainer: Sprite;
    private var poster: Loader;
    private var video: Video;

    private var connection: NetConnection;

    public function Player() {
      stage.align = StageAlign.TOP_LEFT;
      stage.scaleMode = StageScaleMode.NO_SCALE;

      loadPoster(loaderInfo.parameters.poster);
      loadVideo(loaderInfo.parameters.video);
    }

    private function loadPoster(url: String): void {
      posterContainer = new Sprite();
      addChild(posterContainer);



      posterContainer.visible = false;

      stream = new NetStream(connection);
      stream.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
      video.attachNetStream(stream);

      stream.play(videoUrl);
    }

  }
