- Centova Cast - Client Usage Guide
- Centova Cast - Client Reference Manual
Stream Directory
About the Widget
The Stream Directory widget shows a list of the streams that the server hosts. The list contains your stream and the streams of the other accounts on the same server. It shows only the streams that are online now.
For each stream, the list shows:
- The album cover of the current track.
- The title of the stream. If the stream has no title, the list shows the username of the account.
- The artist, the title and the album of the current track.
- The number of listeners, for example
12 listeners.
The widget updates the track information, the listener counts and the online state of each stream in real time. If a stream goes offline, the widget removes it from the list.
This widget is available only if the administrator of the server enables the stream directory for the whole server. If it is not enabled, the widget is not in the Choose Widget list.
Widget Code
The anchor code is a <div> element with the class cc_streamlist_root. Before the widget loads, the element shows
the text Loading ....
The widget shows the same list for all accounts. The Mount Point box of the Widgets page has no effect on this widget.
In the data-xlat attribute of the script code, the text for the listener count contains %d. The widget replaces
%d with the number of listeners.
Advanced Customization
Configurable Options
The advanced code sets this option:
- unstyled
Controls whether the widget applies its own styles. Iftrue, the widget applies no styles, and your own CSS controls the appearance. The default isfalse.
<script type="text/javascript">
(function(){ (window.$CC||(window.$CC={})).streamlist = {
unstyled: true,
};})();
</script>
CSS
The widget uses these CSS classes:
/* container for the default styles; not present if unstyled is true */
.cc_streamlist_basic_style {
}
/* one stream in the list */
.cc_streamlist_entry {
}
/* the album cover of the current track */
.cc_streamlist_entry_image {
}
/* the title of the stream */
.cc_streamlist_entry h3 {
}
/* the artist of the current track */
.cc_streamlist_entry_artist {
}
/* the title of the current track */
.cc_streamlist_entry_title {
}
/* the album of the current track */
.cc_streamlist_entry_album {
}
/* the number of listeners */
.cc_streamlist_entry_listeners {
}