我在A.html里有段JS代码,需要调用B.html源码中的属性,这样的JS语句该怎么写?求帮忙。
下面的JS代码在A.html里,所以搜索出的内容是A页面的,不能寻找B.html里的属性,求怎么让它搜索B.html页面的属性:
$(".start em").click(function(){ //点击开始
var sid=$(this).attr("sonN");
songIndex=sid;
$("#audio").attr("src",sid);
audio=document.getElementById("audio");//获得音元素