User Counter

The example below demonstrates how to display the number of users in a room. When embedded on a page, the code creates a room with the page's url as the room id, and then joins that room. The number of users in the room, hence, reflects the number of users viewing the page.

[View source]

The Code

Here's the code used to embed the user counter on a web page:

<span id="usercounter" style="background-color:#EEEEEE;margin-left:300px;padding:3px;border: 2px inset;border-color:#444444"></span>
<script type="text/javascript" src=""></script>
<script type="text/javascript" src=""></script>
<script type="text/javascript">

Use View source, above, to view the code for the user counter.