html5_rtsp_player icon indicating copy to clipboard operation
html5_rtsp_player copied to clipboard

how to read the password of an rtsp link that contains '@' with streamedian?

Open czb7046 opened this issue 1 year ago • 1 comments

czb7046 avatar Mar 01 '23 10:03 czb7046

Add code like below to "setPlayerSource" function in the "index.html" file to get username and password.

function setPlayerSource(newSource) { let result = newSource.match(/rtsp://(.*)@/); let credentials = result[1].split(':'); let password = credentials[0]; let user = credentials[1];

...

}

victorgrenke avatar Mar 06 '23 05:03 victorgrenke