代码:
<script type="text/javascript">
window.onload=function(){
let mchData ={action:'onIframeReady',displayStyle:'SHOW_CUSTOM_PAGE'}
let postData = JSON. stringify(mchData)
parent.postMessage(postData,'https://payapp.weixin.qq.com')
}
function tiaozhuan(){
let mchData ={action:'jumpOut', jumpOutUrl:'https://www.qq.com'}
let postData = JSON. stringify(mchData)
parent.postMessage(postData,'https://payapp.weixin.qq.com')
}
</script>
weixinpayreturn.php:37 Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://payapp.weixin.qq.com') does not match the recipient window's origin ('https://www.baidu.com').
window.onload @ weixinpayreturn.php:37
load (async)
(anonymous) @ weixinpayreturn.php:33
weixinpayreturn.php:45 Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://payapp.weixin.qq.com') does not match the recipient window's origin ('https://www.baidu.com').
js报错为什么,都是https啊