Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
hung319 authored Jan 14, 2025
1 parent 3bdab3a commit 96f0aa6
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,6 @@ <h1>Tải ảnh NSFW</h1>
<label for="apiSelector">Chọn API:</label>
<select id="apiSelector">
<option value="waifu.pics">Waifu.pics</option>
<option value="nekosapi.com">Nekosapi.com</option>
<option value="konachan(questionable)">Konachan.net(questionable)</option>
<option value="konachan(explicit)">Konachan.net(explicit)</option>
<option value="yande.re(questionable)">Yande.re(questionable)</option>
Expand Down Expand Up @@ -248,7 +247,7 @@ <h1>Tải ảnh NSFW</h1>
const PROXY_URL = 'https://proxy.h4rs.io.vn/cors?url=';
const API_URLS = {
'waifu.pics': 'https://waifu.pics/api/nsfw/waifu',
'nekosapi.com': 'https://api.nekosapi.com/v4/images/random?rating=explicit&limit=1',
// 'nekosapi.com': 'https://api.nekosapi.com/v4/images/random?rating=explicit&limit=1',
'konachan(questionable)': 'https://konachan.net/post.json?tags=order:random+rating:questionable&limit=1',
'konachan(explicit)': 'https://konachan.net/post.json?tags=order:random+rating:explicit&limit=1',
'yande.re(questionable)': 'https://yande.re/post.json?tags=order:random+rating:questionable&limit=1',
Expand Down Expand Up @@ -278,9 +277,9 @@ <h1>Tải ảnh NSFW</h1>
let imageUrl;
if (selectedApi === 'waifu.pics') {
imageUrl = data.url;
} else if (selectedApi === 'nekosapi.com') {
imageUrl = data[0]?.url; // Lấy URL từ phần tử đầu tiên trong mảng
} else {
} /* else if (selectedApi === 'nekosapi.com') {
imageUrl = data[0]?.url; // Lấy URL từ phần tử đầu tiên trong mảng
}*/ else {
imageUrl = data[0]?.file_url;
}

Expand Down

0 comments on commit 96f0aa6

Please sign in to comment.