Guest User

Untitled

a guest
Apr 26th, 2018
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.19 KB | None | 0 0
  1. <script type="text/javascript">
  2. var so = new SWFObject('{$baseurl}/player.swf','player','540','445','8');
  3. so.addVariable('file','{$videourl}/{$videoarray[0].VIDEOID}.flv');
  4. so.addVariable('height','445');
  5. so.addVariable('width','540');
  6. so.addVariable('location','{$baseurl}/player.swf');
  7. so.addVariable('vid','{$videoarray[0].VIDEOID}');
  8. so.addVariable("baseurl","{$baseurl}/");
  9. so.addParam("wmode", "transparent");
  10. so.addParam("vmode", "transparent");
  11. so.write('player');
  12. </script>
  13.  
  14. i am mainly concerned with this line so.addVariable('file','{$videourl}/{$videoarray[0].VIDEOID}.flv');
  15.  
  16. the $videourl contains a single folder where the video files are stored.
  17.  
  18. however, i have another server location that stores another set of videos.
  19.  
  20. how can i make it so that it will attempt to play from either one of the direcotires which has the actual video file.
  21.  
  22.  
  23. for ex)
  24.  
  25. it will attempt to load from one videodir, the file is not there. it will move on to the second videodir that has the file and play it/
  26.  
  27. if both files are present on both videodir, then always play the first one.
  28.  
  29.  
  30. i have two videodir, just incase there is failure in one of them.
Add Comment
Please, Sign In to add comment