Hi,
I'm trying to create multiple videos on a single player. For some reason am getting error '#2048 in the web page. not sure why its happening. below is my code:
<html>
<head>
<p id='preview'>The player will show in this paragraph</p>
<script type='text/javascript' src='http://www.wateraid.org/other/testarea/mediaplayer/swfobject.js'></script>
<script type='text/javascript'>
function CreatePlayer(theFile,go)
{
var s1 = new SWFObject('http://www.wateraid.org/other/testarea/mediaplayer/player.swf','preview','300','200','9');
s1.addParam('allowfullscreen','true');
s1.addParam('allowscriptaccess','always');
s1.addVariable('file','theFile');
s1.addVariable("width","300");
s1.addVariable("height","350");
s1.addVariable("displayheight","225");
if (go) { s1.addVariable("autostart","true"); }
s1.write('preview');
}
</script>
</head>
<body onLoad="CreatePlayer('http://www.wateraid.org/other/testarea/mediaplayer/playlist_1.xml', false)">
<a href="javascript:CreatePlayer('http://www.wateraid.org/other/testarea/mediaplayer/playlist_1.xml', true)">Playlist 1</a><br>
<div id="placeholder"><a href='http://www.macromedia.com/go/getflashplayer'>
get flash</a> to see this player.</div>
</body>
</html>
playlist_1.xml file
<?xml version="1.0" encoding="UTF-8"?>
<playlist version="1" xmlns="http://xspf.org/ns/0/">
<title>WaterAid Videos</title>
<trackList>
<track>
<creator>Nilesh </creator>
<title> Agents of Change</title>
<location>http://www.youtube.com/watch?v=6q9WPXz94LE</location>
<duration>6:00</duration>
</track>
<track>
<title>WaterAid 25 Years</title>
<location>http://www.youtube.com/watch?v=qmICp4IEDG8</location>
<duration>4:00</duration>
</track>
<track>
<title>DRTV 2008</title>
<location>http://www.youtube.com/watch?v=QxtxtYPIb7E</location>
</track>
</trackList>
</playlist>
All the links am refering are working. Can anyone suggest whats wrong with the code?
Thanks,
Nilesh
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"><html>
<head>
<script src='http://www.wateraid.org/other/testarea/mediaplayer/swfobject.js'></script>
<script type='text/javascript'>
function CreatePlayer(theFile, go)
{
var s1 = new SWFObject('http://www.wateraid.org/other/testarea/mediaplayer/player.swf', 'preview', '300', '200', '9.0.124');
s1.addParam('allowscriptaccess', 'always');
s1.addParam('allowfullscreen', 'true');
s1.addVariable('file', theFile);
s1.addVariable('autostart', go);
s1.write('placeholder');
};
</script>
</head>
<body onload="CreatePlayer('http://www.wateraid.org/other/testarea/mediaplayer/playlist_1.xml', false)">
<a href="#" onclick="CreatePlayer('http://www.wateraid.org/other/testarea/mediaplayer/playlist_1.xml', true); return false;">Playlist 1</a>
<br>
<div id="placeholder"><a href='http://www.macromedia.com/go/getflashplayer'>get flash</a> to see this player.</div>
</body>
</html>
<?xml version="1.0" encoding="UTF-8"?><playlist xmlns="http://xspf.org/ns/0/" version="1">
<title>WaterAid Videos</title>
<trackList>
<track>
<creator>Nilesh</creator>
<title> Agents of Change</title>
<location>http://www.youtube.com/watch?v=6q9WPXz94LE</location>
<meta rel='type'>youtube</meta>
<duration>6:00</duration>
</track>
<track>
<title>WaterAid 25 Years</title>
<location>http://www.youtube.com/watch?v=qmICp4IEDG8</location>
<meta rel='type'>youtube</meta>
<duration>4:00</duration>
</track>
<track>
<title>DRTV 2008</title>
<location>http://www.youtube.com/watch?v=QxtxtYPIb7E</location>
<meta rel='type'>youtube</meta>
</track>
</trackList>
</playlist>