Skip to content
Sign upLog in
← Back to Community

How to make an index based search engine

Profile icon
MemeManHimself

I didn't get an answer in my last post, but probably because I said "search engine" rather than "index based search engine". I just need help making one ;-;
I got close in this repl:
Edit: THank yOU cOder100

Answered by Coder100 [earned 5 cycles]
View Answer
Voters
Profile icon
RichardMcKeever
Profile icon
MemeManHimself
Comments
hotnewtop
Profile icon
Coder100

hiii

Profile icon
MemeManHimself

@Coder100
henlo fren

Profile icon
MemeManHimself

oh and

@Coder100
what exactly did you mean by change the value of query?

Profile icon
Coder100

@MemeManHimself
Like:

query = document.querySelector(".search").value

each time the button is clicked.

Profile icon
MemeManHimself
Profile icon
MemeManHimself

@Coder100
I GOT IT TO WORK FINALLY THANK YOU SO MUCH

Profile icon
Coder100

AWESOMEEEEE!!!!

@MemeManHimself

Profile icon
MemeManHimself

@Coder100
TaKe My CyClEs

Profile icon
Coder100
Profile icon
MemeManHimself

@Coder100
lol have a good day :)

Profile icon
Coder100

thanks! You too :D

@MemeManHimself

Profile icon
MemeManHimself

@Coder100
Um just real quick, is there a way that you know of to display them on the website, instead of the console?

Profile icon
Coder100

yeah,

document.getQuerySelector(".result").value = find(query)[0].name
<div class="result"></div>

@MemeManHimself

Profile icon
MemeManHimself

@Coder100
lol it says that getQuerySelector isn't a function. And you don't have to go through fixing it with me, because I know it might take a while, and I don't want to waste your time.

Profile icon
StudentJasonJa2

I do not know, however just search it up on google and there should be many tutorials that are helpfull.

Profile icon
MemeManHimself

@StudentJasonJa2
Well I did search it up, but there are no tutorials, which is why I'm here now.