A
ATeal75
I'm a college student, and I'm having trouble with one of my
assignments. We creating a spell checker in javascript that has to
compare a user submitted word (using forms) to a 5 word dictionary. If
the word is spelled correctly, all we have to do is say so. If not, we
have to suggest a word from the dictionary based on the individual
letters of the word, or ask if the user wants to add the word to the
dictionary, which would incrememnt the dictionary to 6 words as long as
the browser remains open.
I'm not asking for anyone to tell me how to do this, nor am I asking
anyone to do it for me. I'm simply asking if someone could look at
what I have so far and tell me what I'm doing wrong. I'm a long way
from being done, as I've just started getting stuff to work for me.
I'm very limited in my javascript ability, as the pre-requisite class
for this one was a joke.
Here's what I have so far. What I'm trying to do is take the word the
user types in the first text box and when they press the submit button,
it shows up in the second text box:
<script type="text/javascript">
function usersubmit (form){
var x = document.submitform.userentry.value;
document.userWord.userWordResult.value = x;
}
-->
</script>
</head>
<body>
<form name=submitform onsubmit="return checkform(this);">
<input type=text name=userentry>
<input type=submit value="Submit" >
</form>
<form name=userWord onsubmit="return usersubmit(this);">
<input type=text name=userWordResult>
</form>
assignments. We creating a spell checker in javascript that has to
compare a user submitted word (using forms) to a 5 word dictionary. If
the word is spelled correctly, all we have to do is say so. If not, we
have to suggest a word from the dictionary based on the individual
letters of the word, or ask if the user wants to add the word to the
dictionary, which would incrememnt the dictionary to 6 words as long as
the browser remains open.
I'm not asking for anyone to tell me how to do this, nor am I asking
anyone to do it for me. I'm simply asking if someone could look at
what I have so far and tell me what I'm doing wrong. I'm a long way
from being done, as I've just started getting stuff to work for me.
I'm very limited in my javascript ability, as the pre-requisite class
for this one was a joke.
Here's what I have so far. What I'm trying to do is take the word the
user types in the first text box and when they press the submit button,
it shows up in the second text box:
<script type="text/javascript">
function usersubmit (form){
var x = document.submitform.userentry.value;
document.userWord.userWordResult.value = x;
}
-->
</script>
</head>
<body>
<form name=submitform onsubmit="return checkform(this);">
<input type=text name=userentry>
<input type=submit value="Submit" >
</form>
<form name=userWord onsubmit="return usersubmit(this);">
<input type=text name=userWordResult>
</form>