< script src="http://services.companywebcast.com/StateMachine/0.9/js/Cwc.StateMachine.js" type="text/javascript"> < script src="http://services.companywebcast.com/StateMachine/0.9/js/Cwc.StateMachine.MediaRenderer.js" type="text/javascript"> < script type="text/javascript"> window.onload = function() { Cwc.CreateStateMachine(FORMATTER ERROR (":" and "&" not supported in Page Names), function(StateMachine, e) { if (e.Success) { //We've successfully authorized for "apeldoorn/20090702_4/nl", //retrieved its metadata and used it to instantiate a StateMachine. //Subscribe to the event that is fired when the current speaker in this webcast changes StateMachine.State.CurrentSpeakerChangedEvent.Subscribe(function() { var CurrentSpeaker = StateMachine.State.getCurrentSpeaker(); if (CurrentSpeaker.LastName) alert(CurrentSpeaker.LastName); }); //Add the MediaRenderer of this StateMachine to the page. document.getElementById("VideoContainer").appendChild(StateMachine.MediaRenderer); } }); }