<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title></title>
<style>
.p {
border-style: solid;
width: 40rem;
height: 40rem;
border-radius: 50%;
border-color: #999999;
border-width: 0.625rem;
background-color: black;
justify-content: center;
align-items: center;
display: flex;
}
.container {
margin: 0 auto;
width: 360px;
border-radius: 20px;
padding-top: 10px;
text-align: center;
background: #fff
}
.container .item {
padding-left: 100px;
background: #504d58 url(img/409256676536179.png) no-repeat 70px center;
line-height: inherit;
border-bottom: 2px solid #fff;
line-height: 50px;
color: #fff;
text-align: left
}
.container .item:last-of-type {
border-bottom: 0;
border-bottom-left-radius: 20px;
border-bottom-right-radius: 20px;
}
</style>
</head>
<body>
<div class="p">
<div class="container">
<img src="img/95465667653616.jpg" /><br />
<img src="img/05174667653616-2.jpg" />
<div class="item">
我和我的祖国
</div>
<div class="item">
团结就是力量
</div>
<div class="item">
让我们荡起双桨
</div>
<div class="item">
在希望的田野上
</div>
<div class="item">
唱支山歌给党听
</div>
</div>
</div>
</body>
</html>
你题目的解答代码如下:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title></title>
<style>
.p {
border-style: solid;
width: 40rem;
height: 40rem;
border-radius: 50%;
border-color: #999999;
border-width: 0.625rem;
background-color: black;
justify-content: center;
align-items: center;
display: flex;
}
.container {
margin: 0 auto;
width: 360px;
border-radius: 20px;
padding-top: 10px;
text-align: center;
background: #fff
}
.container .item {
padding-left: 100px;
background: #504d58 url(img/409256676536179.png) no-repeat 70px center;
line-height: inherit;
border-bottom: 2px solid #fff;
line-height: 50px;
color: #fff;
text-align: left
}
.container .item:last-of-type {
border-bottom: 0;
border-bottom-left-radius: 20px;
border-bottom-right-radius: 20px;
}
</style>
</head>
<body>
<div class="p">
<div class="container">
<img src="img/95465667653616.jpg" /><br />
<img src="img/05174667653616-2.jpg" />
<div class="item" onclick="play('我和我的祖国.mp3')">
我和我的祖国
</div>
<div class="item" onclick="play('团结就是力量.mp3')">
团结就是力量
</div>
<div class="item" onclick="play('让我们荡起双桨.mp3')">
让我们荡起双桨
</div>
<div class="item" onclick="play('在希望的田野上.mp3')">
在希望的田野上
</div>
<div class="item" onclick="play('唱支山歌给党听.mp3')">
唱支山歌给党听
</div>
</div>
</div>
<audio src="" controls="controls" id="audio">你的浏览器不支持audio标签</audio>
<script type="text/javascript">
function play(url) {
var audio = document.getElementById("audio");
audio.src = url;
audio.play();
}
</script>
</body>
</html>
如有帮助,望采纳!谢谢!
会Vue吗,会Vue有源码
https://github.com/Binaryify/NeteaseCloudMusicApi