Can't post multiple YouTube videos in an swf file.

  • clem_c_rock
  • Novice
  • Novice
  • clem_c_rock
  • Posts: 20

Post 3+ Months Ago

Hello,
I'm making a little gallery of Youtube videos and I can't seem to load more than one in one .swf file.

It seems that once one is loaded - another one can't be played even if you completely remove the container clip from the stage.

I made a quick example of the problem here: http://reseaudesign.com/RN_test/multipl ... test.html;


Here's the code I'm trying:

Code: [ Select ]
var videoURL:String = '';

function load_vid_test_1()
{
  _root.video_2_holder.removeMovieClip();
    
   System.security.allowDomain("http://www.youtube.com");
   System.security.loadPolicyFile("http://www.youtube.com/crossdomain.xml");
 
  _root.createEmptyMovieClip( 'video_1_holder', _root.getNextHighestDepth());
  _root.video_1_holder.createEmptyMovieClip( 'video_1', _root.getNextHighestDepth());

  _root.video_1_holder.loadMovie(_root.videoURL);
    
  _root.video_1_holder._y = 40;
  _root.video_1_holder._xscale = 50;
  _root.video_1_holder._yscale = 50;
}

function load_vid_test_2()
{
  _root.video_1_holder.removeMovieClip();
        
   System.security.allowDomain("http://www.youtube.com");
   System.security.loadPolicyFile("http://www.youtube.com/crossdomain.xml");
 
  _root.createEmptyMovieClip( 'video_2_holder', _root.getNextHighestDepth());
  _root.video_2_holder.createEmptyMovieClip( 'video_2', _root.getNextHighestDepth());

  _root.load_movie_and_stop( _root.video_2_holder.video_2, _root.videoURL, null, 'simple_load');
 
  _root.video_2_holder.loadMovie(_root.videoURL);
 
  _root.video_2_holder._y = 40;
  _root.video_2_holder._x = 250;
  _root.video_2_holder._xscale = 50;
  _root.video_2_holder._yscale = 50;
}
  1. var videoURL:String = '';
  2. function load_vid_test_1()
  3. {
  4.   _root.video_2_holder.removeMovieClip();
  5.     
  6.    System.security.allowDomain("http://www.youtube.com");
  7.    System.security.loadPolicyFile("http://www.youtube.com/crossdomain.xml");
  8.  
  9.   _root.createEmptyMovieClip( 'video_1_holder', _root.getNextHighestDepth());
  10.   _root.video_1_holder.createEmptyMovieClip( 'video_1', _root.getNextHighestDepth());
  11.   _root.video_1_holder.loadMovie(_root.videoURL);
  12.     
  13.   _root.video_1_holder._y = 40;
  14.   _root.video_1_holder._xscale = 50;
  15.   _root.video_1_holder._yscale = 50;
  16. }
  17. function load_vid_test_2()
  18. {
  19.   _root.video_1_holder.removeMovieClip();
  20.         
  21.    System.security.allowDomain("http://www.youtube.com");
  22.    System.security.loadPolicyFile("http://www.youtube.com/crossdomain.xml");
  23.  
  24.   _root.createEmptyMovieClip( 'video_2_holder', _root.getNextHighestDepth());
  25.   _root.video_2_holder.createEmptyMovieClip( 'video_2', _root.getNextHighestDepth());
  26.   _root.load_movie_and_stop( _root.video_2_holder.video_2, _root.videoURL, null, 'simple_load');
  27.  
  28.   _root.video_2_holder.loadMovie(_root.videoURL);
  29.  
  30.   _root.video_2_holder._y = 40;
  31.   _root.video_2_holder._x = 250;
  32.   _root.video_2_holder._xscale = 50;
  33.   _root.video_2_holder._yscale = 50;
  34. }



Thanks,
Clem

Post Information

  • Total Posts in this topic: 1 post
  • Users browsing this forum: No registered users and 5 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.