Newer Version Available

This content describes an older version of this product. View Latest

Example: Interactive Visualforce Page without Replay

The interactive Visualforce example shows you how to implement Streaming API from a Visualforce page. The sample uses the Dojo library and CometD to subscribe to PushTopic events.

On the Visualforce page, you enter the name of the PushTopic channel you want to subscribe to and click Subscribe to receive notifications on the page. Click Unsubscribe to unsubscribe from the channel and stop receiving notifications.

This sample doesn’t use the replay extension and can’t receive past events. To use a replay option, check out Example: Subscribe to and Replay Events Using a Visualforce Page.

Note