I am a very very beginner in Javascript and am trying to use only very basics. I am trying to only allow two certain words to be accepted into a variable prompt. If anything else other than the two allowed words are entered, I want to display a message saying only the two words are allowed, and to try again
Tag: case-sensitive
Javascript: highlight substring keeping original case but searching in case insensitive mode
I’m trying to write a “suggestion search box” and I cannot find a solution that allows to highlight a substring with javascript keeping the original case. For example if I search for “ca” I search server side in a case insensitive mode and I have the following results: Calculator calendar ESCAPE I would like to view the search string in