From 321b88e235bc15ee8ace8c3bfa420e9283d4eac0 Mon Sep 17 00:00:00 2001 From: zhetic <> Date: Sat, 22 May 2021 14:45:10 +0300 Subject: [PATCH] make search only work on load --- catalog.html | 2 +- css/stylesheet.css | 1 + js/title_list.js | 8 +++----- search.html | 9 ++------- 4 files changed, 7 insertions(+), 13 deletions(-) diff --git a/catalog.html b/catalog.html index cadcd00..0e0d862 100644 --- a/catalog.html +++ b/catalog.html @@ -42,7 +42,7 @@ diff --git a/css/stylesheet.css b/css/stylesheet.css index a1eccd2..5d23aaa 100644 --- a/css/stylesheet.css +++ b/css/stylesheet.css @@ -95,6 +95,7 @@ a:visited { #content { position: absolute; width: 80%; + height: auto; left: 10%; top: 5em; bottom: 0em; diff --git a/js/title_list.js b/js/title_list.js index a52f94a..65ead02 100644 --- a/js/title_list.js +++ b/js/title_list.js @@ -6,8 +6,6 @@ function load_titles(remote) { if(remote == ""){ return; } - base = remote; - remote += "/manga/search?title=a"; fetch(remote) .then(res => res.json()) .then(function (res) { @@ -25,11 +23,11 @@ function load_titles(remote) { )) .appendChild(Object.assign( document.createElement("a"), - {href: "./title.html?id="+manga["id"]} + {href: "/title.html?id="+manga["id"]} )) .appendChild(Object.assign( document.createElement("img"), - {className: "thumbnail", src: base+"/thumbnail/"+manga["id"]+".webp"} + {className: "thumbnail", src: "/instance/thumbnail/"+manga["id"]+".webp"} )); //title first_row.appendChild(Object.assign( @@ -38,7 +36,7 @@ function load_titles(remote) { )) .appendChild(Object.assign( document.createElement("a"), - {href: "./title.html?id="+manga["id"]} + {href: "/title.html?id="+manga["id"]} )) .appendChild(Object.assign( document.createElement("b"), diff --git a/search.html b/search.html index 3e97da9..16f405f 100644 --- a/search.html +++ b/search.html @@ -75,16 +75,11 @@