How to unsubscribe manually?

I have asked a related question before

OpenTok - How to publish/unpublish manually?

Now I am struggling to do the unsubscribe manually.

http://www.tokbox.com/opentok/api/tools/js/documentation/api/Session.html#unsubscribe

I have already followed the code but I still see the video. It is supposed to remove the video right?

EDIT: I discovered a mistake in the example code in the unsubscribe section. unsubscribe() accepts subscriber objects but the code passes a stream object.


In case anyone else has the some error, heres some sample code snippet:
var subscriber;

After you create a subscriber:
subscriber = session.subscribe( streamObject );

To unsubscribe:
session.unsubscribe(subscriber);

链接地址: http://www.djcxy.com/p/66134.html

上一篇: 将opentok视频会议集成到parse.com + iOS应用程序中

下一篇: 如何手动取消订阅?