WP-Webrtc2 plugin

WP-Webrtc2 plugin

Table of Contents

Packages

core
includes
settings
main

Classes

WebRTC2_Core
WebRTC2_Shortcode
WebRTC2_Stun_Client
WebRTC2_List_Table_Srv
WebRTC2_List_Table_Stat

Functions

webrtc2_create_tables()  : bool
Create tables: webrtc2_call_statistics.
webrtc2_create_table_countries()  : bool
Create table: webrtc2_countries.
webrtc2_create_table_call_stat()  : bool
Create table: webrtc2_call_stat.
webrtc2_create_table_stun_servers()  : bool
Create table: webrtc2_stun_servers.
webrtc2_who_is()  : array<string|int, mixed>
Select name of WHO-IS provider.
webrtc2_ip_api()  : array<string|int, mixed>
Retrieve ip information from the provider IP_API.
webrtc2_ip_info()  : array<string|int, mixed>
Retrieve ip information from the provider IP_info.
webrtc2_sx_geo()  : array<string|int, mixed>
Retrieve ip information from the provider SxGeo.
webrtc2_geobytes()  : array<string|int, mixed>
Retrieve ip information from the provider Geobytes.
webrtc2_country_name()  : string
Retrieve information of country of visitor.
webrtc2_getClosestTimezone()  : string
Attempts to find the closest timezone by coordinates.
webrtc2_tbl_users()  : mixed
Prepare table for Profile: tbl_users.
webrtc2_tbl_contact()  : mixed
Prepare table for Profile: tbl_contact.
webrtc2_validateBrowserName()  : string
Validate Browser name.
webrtc2_validateState()  : string
Validate state of videochat.
webrtc2_validateCmd()  : string
Validate command of signaling.
webrtc2_validateMsg()  : string
Validate Msg (Strip HTML and PHP tags from a string).
webrtc2_validateTypeSdp()  : string
Validate Type SDP.
webrtc2_validateBrowser()  : string
Validate HTTP_USER_AGENT.
webrtc2_validateLogin()  : string
Validate User login.
webrtc2_validateIP()  : string
Validate user IP.
webrtc2_validateURI()  : string
Validate URI.
webrtc2_sign()  : mixed
WebRTC signaling Server.
webrtc2_send_frontend()  : mixed
Send info of members video-chat to the browser of client.
webrtc2_sse()  : mixed
Collecting and saved information about video chat participants.
webrtc2_build_template_blank()  : mixed
Used for client application: Java client.
webrtc2_choose_stun()  : mixed
Choose stun server name for user video chat.
webrtc2_receive_stun()  : mixed
Receive data of stun server name.
cmp()  : mixed
Helper function for uasort($data, "cmp").
webrtc2_sql_countries()  : string
Populate the data in table prefix_watchman_site_countries.
webrtc2_stun_servers()  : string
Populate the data in table prefix_webrtc2_stun_servers.
webrtc2_uninstall()  : mixed
Delete all options and tables of plugin WP-WebRTC2.
webrtc2_textdomain()  : mixed
Localization of plugin.
webrtc2_enqueue_scripts_backend()  : mixed
Register javascripts, css for backend.
webrtc2_scripts_css()  : mixed
Register javascripts, css for frontend.
webrtc2_activation()  : mixed
Performed when the plugin is activation.
webrtc2_deactivation()  : mixed
Performed when the plugin is deactivation.

Functions

webrtc2_create_tables()

Create tables: webrtc2_call_statistics.

webrtc2_create_tables() : bool
Return values
bool

webrtc2_create_table_countries()

Create table: webrtc2_countries.

webrtc2_create_table_countries() : bool
Return values
bool

webrtc2_create_table_call_stat()

Create table: webrtc2_call_stat.

webrtc2_create_table_call_stat() : bool
Return values
bool

webrtc2_create_table_stun_servers()

Create table: webrtc2_stun_servers.

webrtc2_create_table_stun_servers() : bool
Return values
bool

webrtc2_who_is()

Select name of WHO-IS provider.

webrtc2_who_is(string $ip_or_dns, string $who_is) : array<string|int, mixed>
Parameters
$ip_or_dns : string

IP or DNS of server.

$who_is : string

Name of who is provider.

Return values
array<string|int, mixed>

webrtc2_ip_api()

Retrieve ip information from the provider IP_API.

webrtc2_ip_api(string $user_ip) : array<string|int, mixed>
Parameters
$user_ip : string

User ip.

Return values
array<string|int, mixed>

In format json.

webrtc2_ip_info()

Retrieve ip information from the provider IP_info.

webrtc2_ip_info(string $user_ip) : array<string|int, mixed>
Parameters
$user_ip : string

User ip.

Return values
array<string|int, mixed>

In format json.

webrtc2_sx_geo()

Retrieve ip information from the provider SxGeo.

webrtc2_sx_geo(string $user_ip) : array<string|int, mixed>
Parameters
$user_ip : string

User ip.

Return values
array<string|int, mixed>

In format json.

webrtc2_geobytes()

Retrieve ip information from the provider Geobytes.

webrtc2_geobytes(string $user_ip) : array<string|int, mixed>
Parameters
$user_ip : string

User ip.

Return values
array<string|int, mixed>

In format json.

webrtc2_country_name()

Retrieve information of country of visitor.

webrtc2_country_name(string $country_code) : string
Parameters
$country_code : string

Country code.

Return values
string

User country name.

webrtc2_getClosestTimezone()

Attempts to find the closest timezone by coordinates.

webrtc2_getClosestTimezone(string $lat, string $lon) : string
Parameters
$lat : string

Latitude.

$lon : string

Longitude.

Return values
string

Timezone.

webrtc2_tbl_contact()

Prepare table for Profile: tbl_contact.

webrtc2_tbl_contact() : mixed

webrtc2_validateBrowserName()

Validate Browser name.

webrtc2_validateBrowserName(mixed $browser_name) : string
Parameters
$browser_name : mixed
Return values
string

State.

webrtc2_validateState()

Validate state of videochat.

webrtc2_validateState(string $state) : string
Parameters
$state : string

Start or Stop.

Return values
string

State.

webrtc2_validateCmd()

Validate command of signaling.

webrtc2_validateCmd(string $cmd) : string
Parameters
$cmd : string

Unique command identifier of signaling.

Return values
string

Command.

webrtc2_validateMsg()

Validate Msg (Strip HTML and PHP tags from a string).

webrtc2_validateMsg(string $msg) : string

Limits the length of the input string.

Parameters
$msg : string

Message of user.

Return values
string

Message.

webrtc2_validateTypeSdp()

Validate Type SDP.

webrtc2_validateTypeSdp(string $type_sdp) : string
Parameters
$type_sdp : string

Type SDP.

Return values
string

Type SDP.

webrtc2_validateBrowser()

Validate HTTP_USER_AGENT.

webrtc2_validateBrowser(mixed $user_agent) : string
Parameters
$user_agent : mixed
Return values
string

HTTP_USER_AGENT.

webrtc2_validateLogin()

Validate User login.

webrtc2_validateLogin(string $login) : string
Parameters
$login : string

User login.

Return values
string

User login.

webrtc2_validateIP()

Validate user IP.

webrtc2_validateIP() : string
Return values
string

User IP.

webrtc2_validateURI()

Validate URI.

webrtc2_validateURI() : string
Return values
string

URI.

webrtc2_sign()

WebRTC signaling Server.

webrtc2_sign() : mixed

webrtc2_send_frontend()

Send info of members video-chat to the browser of client.

webrtc2_send_frontend(string $data1, string $data2) : mixed
Parameters
$data1 : string

All users online on page video-chat.

$data2 : string

List of guests for each video-chat host.

webrtc2_sse()

Collecting and saved information about video chat participants.

webrtc2_sse() : mixed

webrtc2_build_template_blank()

Used for client application: Java client.

webrtc2_build_template_blank() : mixed

Since the client application works on mobile devices with a small screen, all unnecessary content is removed from the video chat page and only the shortcode remains.

webrtc2_choose_stun()

Choose stun server name for user video chat.

webrtc2_choose_stun() : mixed

webrtc2_receive_stun()

Receive data of stun server name.

webrtc2_receive_stun(mixed $user_time_zone) : mixed
Parameters
$user_time_zone : mixed

cmp()

Helper function for uasort($data, "cmp").

cmp(mixed $a, mixed $b) : mixed
Parameters
$a : mixed
$b : mixed

webrtc2_sql_countries()

Populate the data in table prefix_watchman_site_countries.

webrtc2_sql_countries() : string
Return values
string

webrtc2_stun_servers()

Populate the data in table prefix_webrtc2_stun_servers.

webrtc2_stun_servers() : string
Return values
string

webrtc2_uninstall()

Delete all options and tables of plugin WP-WebRTC2.

webrtc2_uninstall() : mixed

webrtc2_textdomain()

Localization of plugin.

webrtc2_textdomain() : mixed

webrtc2_enqueue_scripts_backend()

Register javascripts, css for backend.

webrtc2_enqueue_scripts_backend() : mixed

webrtc2_scripts_css()

Register javascripts, css for frontend.

webrtc2_scripts_css() : mixed

webrtc2_activation()

Performed when the plugin is activation.

webrtc2_activation() : mixed

During activation, creates table in the database:

webrtc2_countries, webrtc2_call_stat, webrtc2_stun_servers

webrtc2_deactivation()

Performed when the plugin is deactivation.

webrtc2_deactivation() : mixed

Delete cron events: webrtc2_truncate, webrtc2_update, webrtc2_update_repeat

Search results