This commit is contained in:
威勝 張 2024-02-03 14:46:22 +08:00
commit dd68a1cc08

View File

@ -7,7 +7,6 @@
<style>
#img_id {
width: 80%;
display: block; /* 使圖像為塊級元素,以便使用 margin:auto; */
margin: auto; /* 將圖像置中 */
}
@ -51,14 +50,17 @@
<!--彈跳視窗-->
<div>
<dialog id="webcam_view" style="width:80%;">
<div>
<button class="btn btn-danger" style="float:right" onclick="RTSP_Close();"> 關閉</button></br>
<img id="img_id" style="width:50%"/>
</div>
</dialog>
</div>
<!--跳轉頁面-->
<script>
function Yuntech_RTSP() {
window.open ("http://140.125.50.178:7006/","_blank");
}
</script>
<!--獲取資料-->
@ -131,12 +133,9 @@
IP_1 = IP
$.ajax({
type: "GET",
url: 'http://140.125.20.183:7705/IP/'+IP,
headers: {
'Authorization': token
},
success: function (response) {
//webcam_view.showModal()
stop = false
RTSP_START(response)
token_check = "true"
@ -150,9 +149,7 @@
console.log(IP_1)
$.ajax({
type: "GET",
url: 'http://140.125.20.183:7705/IP/' + IP_1,
headers: {
'Authorization': token
},
success: function (response) {
//webcam_view.showModal()
@ -174,7 +171,6 @@
img = document.getElementById("img_id")
img.src = img_base_64
if (stop == false){
setTimeout('CAM_RTSP_1()', 20);
}
}
@ -183,7 +179,6 @@
<!--關閉串流-->
<script>
function RTSP_Close(){
//webcam_view.close()
stop = true
document.getElementById("RTSP_stop_id").style.display="none"
}