Alex Gillis
Alex Gillis

Reputation: 23

Realtime updates from multiple pusher channels

I am wondering if it is able to import data from multiple pusher channels.

For one channel you use var channel = pusher.subscribe('channel_name'); I've tried var channel = pusher.subscribe('channel1','channel2'); but that doesn't seem to work.

Looking through the docs I have found nothing about this. Any help would be gratefully appreciated!

Upvotes: 2

Views: 1675

Answers (1)

leggetter
leggetter

Reputation: 15467

You have to subscribe to each channel individually e.g.

var channel1 = pusher.subscribe( 'channel1' );
var channel2 = pusher.subscribe( 'channel2' );

Upvotes: 4

Related Questions