-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
39 lines (37 loc) · 1.8 KB
/
Copy pathindex.html
File metadata and controls
39 lines (37 loc) · 1.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<!DOCTYPE html>
<html lang="ch">
<head>
<meta charset="utf-8"/>
<title>pixiv图片查询</title>
<script>
function checkInput() {
text = document.getElementById("inputer").value;
type_pic = document.getElementsByName("tp");
for(var i=0; i<3; i++) {
if(type_pic[i].checked) {
type = type_pic[i].value;
}
}
image_e = document.getElementById('image');
image_e.src = "https://pixiv.re/" + text + "." + type;
}
</script>
</head>
<body>
<p>在框内输入作品ID(如82775556)再按“查询”按钮即可查看对应作品</p>
<p>对于一个ID有多张图片的,请用pid+图片序号的格式输入(例:78286152-2:id为78286152的作品的第2张图)</p>
<p>(图片为动态产生,准确档案类型会以Content-Type header发送)</p>
<hr/>
<input type="text" class="i" size="10" autofocus id="inputer" placeholder="输入pid" required="required"/>
<button type="button" class="btn" onclick="checkInput()">查询</button>
<br/>
<p>图片格式:</p>
<input type="radio" name="tp" id="type_pic" value="png" checked="checked"/>png
<input type="radio" name="tp" id="type_pic" value="jpg"/>jpg
<input type="radio" name="tp" id="type_pic" value="gif"/>gif
<hr/>
<img id="image" src="https://pixiv.re" width="500" alt="图片不存在或无法查看图片(确定pid存在且图片格式正确)"/>
<noscript>无法使用JavaScript</noscript>
<a href="https://github.com/Yweiwu30/pixivTools">下载exe</a>
</body>
</html>