1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

add linux version of band check app; add web version of band check app

This commit is contained in:
wenjiegit 2013-12-26 07:24:19 +08:00
parent 237fb13e1b
commit 3af83fb02a
8 changed files with 1188 additions and 0 deletions

View file

@ -0,0 +1,27 @@
// for bw to init url
// url: scheme://host:port/path?query#fragment
function srs_init_bwt(rtmp_url, hls_url) {
update_nav();
if (rtmp_url) {
//var query = parse_query_string();
var search_filed = String(window.location.search).replace(" ", "").split("?")[1];
$(rtmp_url).val("rtmp://" + window.location.host + ":" + 1935 + "/app?" + search_filed);
}
if (hls_url) {
$(hls_url).val(build_default_hls_url());
}
}
function srs_bwt_check_url(url) {
if (url.indexOf("key") != -1 && url.indexOf("vhost") != -1) {
return true;
}
return false;
}
function srs_bwt_build_default_url() {
var url_default = "rtmp://" + window.location.host + ":" + 1935 + "/app?key=35c9b402c12a7246868752e2878f7e0e&vhost=bandcheck.srs.com";
return url_default;
}