http://www.99real.com/music/play/83/83578.htm
这是前端代码,要用javascript 读取。你可以参看参看 <a id='a1' href="/news/123.html">新闻1</a><a id='a2' href="/news/234.html">新闻2</a><a id='a3' href="/news/345.html">新闻3</a><p>
以下是读出的数据
<div id='a1h'></div>
<div id='a2h'></div>
<div id='a3h'></div>
<p>
<div id='a1s'></div>
<div id='a2s'></div>
<div id='a3s'></div>
<script>
function reada(id){
return(document.getElementById(id).innerHTML)
}
function readH(id){
return(document.getElementById(id).href)
}
document.getElementById('a1h').innerHTML=reada('a1')
document.getElementById('a2h').innerHTML=reada('a2')
document.getElementById('a3h').innerHTML=reada('a3')document.getElementById('a1s').innerHTML=readH('a1')
document.getElementById('a2s').innerHTML=readH('a2')
document.getElementById('a3s').innerHTML=readH('a3')
</script>
欢迎分享,转载请注明来源:优选云