Skip to content

Commit

Permalink
iframe地址错误
Browse files Browse the repository at this point in the history
  • Loading branch information
xiangyuecn committed Nov 17, 2020
1 parent 168ec0d commit 3c742a4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion assets/ztest_iframe.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@
document.querySelector(".box").innerHTML='<iframe src="'+url+'" '+(allow?'allow="camera;microphone"':'')+' class="iframe" style="width:98%;height:85vh; border:4px solid #0B1"></iframe>';
};

var iframeUrl=decodeURIComponent((/[?&#]iframeUrl=((https?:|\/)[^&#]+)/i.exec(location.href)||[])[1]||"");
var iframeUrl=decodeURIComponent((/[?&#]iframeUrl=((https?(:|%3A)|\/)[^&#]+)/i.exec(location.href)||[])[1]||"");
console.log("iframeUrl: "+iframeUrl);
if(!iframeUrl){
reclog('提供的iframeUrl参数无效',1);
}else{
Expand Down

0 comments on commit 3c742a4

Please sign in to comment.