网页Sources如下
<h4>Title:虞美人</br>Author:青空なん</br>PID:72027283</br>Tags:FGO,Fate/GrandOrder,虞美人,Yu Miaoyi,虞美人(Fate),虞美人(Fate),魅惑の谷間,魅惑的**,裸足,赤脚</h4>
<a href="https://www.pixiv.net/artworks/72027283" target="_blank">
<img id="img" src="https://i.pixiv.cat/c/540x540_70/img-master/img/2018/12/09/00/08/05/72027283_p0_master1200.jpg" alt="72027283.png" style="height:50%" onerror="reloadI()"/></br>
</a>
<button name= "reload" onclick="location.reload()" style="margin-top:5px;margin-right:5px">Reload</button>
<a href="https://i.pixiv.cat/img-original/img/2018/12/09/00/08/05/72027283_p0.png" target="_blank">
<button name= "download" style="margin-top:5px;margin-right:5px">Download</button>
</a>
<script type="text/javascript">
var img=document.getElementById('img');
function reloadI(){
img.src="https://i.pixiv.cat/c/540x540_70/img-master/img/2018/12/09/00/08/05/72027283_p0_master1200.jpg?"+Math.random();
}
</script>
例:json数据如下
{"code":0,"msg":"","count":1,"data":[{"pid":83914212,"p":0,"uid":28175731,"title":"abi ","author":"MerryJ","r18":false,"width":1653,"height":2386,"tags":["FGO","Fate/GrandOrder","女女の子","女女の子" ","アビゲイル・ウィリアムズ(水着)","阿比盖尔·威廉姆斯(泳装)","アビゲイル・ウィリアムズ(Fate)","阿比盖尔·威廉姆斯(斯着着)","水","泳装","アビゲイル・ウィリアムズ〔夏〕","阿比盖尔·威廉姆斯(夏)","へそ出し","midriff"],"url":"https://i.pixiv.cat/img- original/img/2020/08/25/00/00/07/83914212_p0.jpg"}]}
然而json数据这样写代码就能做到:
关键词
a:$访问 (这里是api)$
b:$取中间 Э %a%Э"url":"Э"$
c:$替换 € %b%€\€$
d:$取中间 Э %a%Э"uid":Э"$
画师ID:%d%\r
图片链接:%c%
±img=%c%±
但是HTML数据实属难道我了,请问有什么方法可以做到同样效果吗?
附:json数据代码效果图
<h4>Title:虞美人</br>Author:青空なん</br>PID:72027283</br>Tags:FGO,Fate/GrandOrder,虞美人,Yu Miaoyi,虞美人(Fate),虞美人(Fate),魅惑の谷間,魅惑的**,裸足,赤脚</h4>
<a href="https://www.pixiv.net/artworks/72027283" target="_blank">
<img id="img" src="https://i.pixiv.cat/c/540x540_70/img-master/img/2018/12/09/00/08/05/72027283_p0_master1200.jpg" alt="72027283.png" style="height:50%" onerror="reloadI()"/></br>
</a>
<button name= "reload" onclick="location.reload()" style="margin-top:5px;margin-right:5px">Reload</button>
<a href="https://i.pixiv.cat/img-original/img/2018/12/09/00/08/05/72027283_p0.png" target="_blank">
<button name= "download" style="margin-top:5px;margin-right:5px">Download</button>
</a>
<script type="text/javascript">
var img=document.getElementById('img');
function reloadI(){
img.src="https://i.pixiv.cat/c/540x540_70/img-master/img/2018/12/09/00/08/05/72027283_p0_master1200.jpg?"+Math.random();
}
</script>
例:json数据如下
{"code":0,"msg":"","count":1,"data":[{"pid":83914212,"p":0,"uid":28175731,"title":"abi ","author":"MerryJ","r18":false,"width":1653,"height":2386,"tags":["FGO","Fate/GrandOrder","女女の子","女女の子" ","アビゲイル・ウィリアムズ(水着)","阿比盖尔·威廉姆斯(泳装)","アビゲイル・ウィリアムズ(Fate)","阿比盖尔·威廉姆斯(斯着着)","水","泳装","アビゲイル・ウィリアムズ〔夏〕","阿比盖尔·威廉姆斯(夏)","へそ出し","midriff"],"url":"https://i.pixiv.cat/img- original/img/2020/08/25/00/00/07/83914212_p0.jpg"}]}
然而json数据这样写代码就能做到:
关键词
a:$访问 (这里是api)$
b:$取中间 Э %a%Э"url":"Э"$
c:$替换 € %b%€\€$
d:$取中间 Э %a%Э"uid":Э"$
画师ID:%d%\r
图片链接:%c%
±img=%c%±
但是HTML数据实属难道我了,请问有什么方法可以做到同样效果吗?
附:json数据代码效果图
附件
-
281.7 KB 查看: 5