View Categories

WpStream Shortcodes

3 min read

WpStream with built-in blocks for Elementor Page Builder or Visual Bakery Page Builder, but you may use other page builders or maybe you would like to only stick to the WordPress Interface.

In this case, here is a list of available shortcodes and how you can use them:

wpstream_player #

This shortcode will display a video player with a particular ID or the last event created for a particular User Id.

Possible inputs 

id

the event/Vod id, witch can be Free-To-View-Live-Channels, Free-To-View-VOds, or a WooCoomerce product id 

user_id

in this case, we will display a player for the first event of that particular user. This is useful when you want to let your user do a live stream, and you want to display the player on a specific page.

Examples 

In page via shortcode block

[wpstream_player id="1234" ][/wpstream_player]

Or 

Via PHP code

echo do_shortcode( '[wpstream_player id="1234" ][/wpstream_player]' );

wpstream_go_live #

This shortcode will display the start event controls for a particular event id.

Possible Inputs

Id

the event id

Example 

In page via shortcode block

[wpstream_go_live id="1234" ][/wpstream_go_live]

Or 

Via PHP code

echo do_shortcode( '[wpstream_go_live id="1234" ][/wpstream_go_live]' );

wpstream_list_media_channels #

This shortcode will display a list of free live-streaming events or pay-per-view events (WooCommerce Products)

Possible inputs

media_number

the number of items                         

product_type_free_paid      

0 or 1 ; 0 means free events, while 1 means paid events     ‘,

product_show_live                 

yes or no. “Yes” shows only live events, while “no” show all type of events (active or inactive)

free_label

the link Link Label for free items.

order_by

0 means order by date ASC, 1 means order by date DESC, 2 means order by title ASC, 3 means order by title DESC

Examples

In page via shortcode block

[wpstream_list_media_channels  media_number='9' product_type_free_paid='0'   product_show_live='no'  free_label='click here' order_by='1' ][/wpstream_list_media_channels]

Or 

Via PHP code

echo do_shortcode( [wpstream_list_media_channels  media_number='9' product_type_free_paid='0'   product_show_live='no'  free_label='click here' order_by='1' ][/wpstream_list_media_channels] );

wpstream_list_media_vod #

This shortcode will display a list of free VODs or pay-per-view VODs (WooCommerce Products)

Possible Inputs

media_number

the number of items                         

product_type_free_paid

 0 or 1 ; 0 means free events while 1 means paid events

free_label

Link Label for free items

order_by

0 means order by date ASC, 1 means order by date DESC,2 means order by title ASC, 3 means order by title DESC

Examples

In page via shortcode block

[wpstream_list_media_vod  media_number='9' product_type_free_paid='0'    free_label='click here VOD' order_by='1' ][/wpstream_list_media_vod]

Or via Php code

Via PHP codedo_shortcode(“[wpstream_list_media_vod  media_number='9' product_type_free_paid='0'    free_label='click here VOD' order_by='1' ][/wpstream_list_media_vod]”);

Here is a screen capture with all the shortcodes added to a classic WordPress Page.