The interface for the Verdurian dictionary is subtiy broken: you're using HTML form elements, but rather than using a form you've tied everything to an onclick handler on the button. As a result, if you type a word into the input box and press Enter you get something else happening—the first time I tried it I got an internal server error, but other attempts just refreshed the page.
I am no expert but it seems like this should be relatively simple to fix: add a wrapper <form> element, make the List button a <input type="submit"> rather than merely a <input type="button">, and call the existing Javascript in the onsubmit event of the form rather than the onclick event of the button.
Verdurian Dictionary bug
Re: Verdurian Dictionary bug
As long as that wouldn’t take away a function of the current page: you can press List without entering anything to get the whole dictionary.
-
- Site Admin
- Posts: 3040
- Joined: Sun Jul 08, 2018 5:46 am
- Location: Right here, probably
- Contact:
Re: Verdurian Dictionary bug
Unfortunately the fix doesn't work. I changed the form element to
<form name="theform" onsubmit="process();">
and the input button to
<input type="submit" value="List" >
and then nothing happens when the button is pushed.
(As usual, this is probably outmoded rather than incorrect practice. Google's AI thinks that onsubmit was added in 1999, and yeah, my site dates back before that.)
<form name="theform" onsubmit="process();">
and the input button to
<input type="submit" value="List" >
and then nothing happens when the button is pushed.
(As usual, this is probably outmoded rather than incorrect practice. Google's AI thinks that onsubmit was added in 1999, and yeah, my site dates back before that.)
Re: Verdurian Dictionary bug
I am little help—my policy regarding Javascript is to not touch it and hope it goes away on its own. (I saw the same "discouraged" warnings on MDN; the reason given is that it's a mixture of concerns similar to using <FONT COLOR=#FF0000> all over the place rather than a CSS document.)