Hi' this is great player, but why seems to difficult to make javascript integration works.
this is my code:
<script type="text/javascript">
var so = new SWFObject('player.swf','jstest','400','220','8');
so.addParam('allowscriptaccess','always');
so.addParam('allowfullscreen','true');
so.addVariable('width','400');
so.addVariable('height','220');
so.addVariable('file','video.flv');
so.addVariable('javascriptid','jstest');
so.addVariable('enablejs','true');
so.write('container');
function sendEvent(swf,typ,prm) {
thisMovie(swf).sendEvent(typ,prm);
};
function getUpdate(typ,pr1,pr2,swf) {};
function thisMovie(swf) {
if(navigator.appName.indexOf("Microsoft") != -1) {
return window[swf];
} else {
return document[swf];
}
};
function getUpdate(typ,pr1,pr2,swf) {
if(typ == 'state') {
alert('the current state is: '+pr1+');');
}
};
function loadFile(swf,obj) {
thisMovie(swf).loadFile(obj);
};
</script>Call it with this:
<a href="javascript:loadFile('jstest',{file:'/ironman.flv'})">load a single file</a>Why it's not working? what part did i miss?
Thanks a lot..
Sorry, forgot to tell. This is error that i always got until now:
thisMovie(swf).loadFile is not a function