侧边栏壁纸
博主头像
Gstory's Blog博主等级

每天进步一点点!

  • 累计撰写 108 篇文章
  • 累计创建 23 个标签
  • 累计收到 11 条评论

目 录CONTENT

文章目录

QQ音乐歌单导出

gstory
2023-05-15 / 1 评论 / 0 点赞 / 431 阅读 / 2234 字 / 正在检测是否收录...
温馨提示:
本文最后更新于 2023-12-25,若内容或图片失效,请留言反馈。部分素材来自网络,若不小心影响到您的利益,请联系我们删除。

打开地址替换歌单ID
https://y.qq.com/musicmac/v6/playlist/detail.html?id=歌单ID

打开浏览器的检查->Console->执行代码

var songList = [];
Array.from(document.querySelectorAll(".songlist__item")).map((v) => {
  var song = {};
  song["singer"] = v.querySelector(".singer_name").title;
  song["song"] = v.querySelector(".mod_songname__name").title;
  songList.push(song);
});
console.log(JSON.stringify(songList));

测试
https://y.qq.com/musicmac/v6/playlist/detail.html?id=1135983683

[{"singer":"星弟","song":"最后一面"},{"singer":"姜玉阳","song":"最后一次相依偎"},{"singer":"优优","song":"爱到最后只剩下回忆"},{"singer":"宋孟君","song":"最后的安慰"},{"singer":"何安琪","song":"最后一次"},{"singer":"安苏羽","song":"最后的一句挽留"},{"singer":"胥拉齐","song":"最后一封信"},{"singer":"庄心妍","song":"最后的温柔"},{"singer":"夏婉安","song":"最后的晚安"},{"singer":"孙露","song":"最后一次"},{"singer":"单色凌","song":"最后的皇后"},{"singer":"格子兮","song":"最后的约定"},{"singer":"shelly佳","song":"最后一晚"},{"singer":"蒋雪儿","song":"最后的微笑"},{"singer":"田元","song":"最后的温柔"},{"singer":"本兮","song":"最后的最后"},{"singer":"胡文婧","song":"最后一刻才明白"},{"singer":"冷漠","song":"最后一次牵手"},{"singer":"夏婉安","song":"夜声带走最后一个我"}]

12.25更新

https://i.y.qq.com/n2/m/share/details/taoge.html?ADTAG=ryqq.playlist&id=歌单ID
打开浏览器的检查->Console->执行代码

var songList = [];
Array.from(document.querySelectorAll(".song_list__item")).map((v) => {
  var song = {};
  song["name"] = v.querySelector(".song_list__txt").textContent;
  var artist = v.querySelector(".song_list__desc").textContent;
  if(artist.indexOf(" · ")!=-1){
      song["artist"] = artist.match(/(\S*) · /)[1];
  }else{
      song["artist"] = artist;
  }
  songList.push(song);
});
console.log(JSON.stringify(songList));

测试
https://i.y.qq.com/n2/m/share/details/taoge.html?ADTAG=ryqq.playlist&id=8390262816

0

评论区