0

So i got this exercise at my school and i cant for the life of me find the answer here is : Take advantage of the onchange event to make a page with a text box where if the user types a number, it will turn yellow if you type a String then turn green and leave it blank to make it red. please help

3
  • 1
    Show an attempt... May 28, 2018 at 15:13
  • i dont know where to use the onchange event May 28, 2018 at 15:17
  • Since you are in a class which covers HTML and JavaScript you should be able to show us a text box at minimum. If you can't do that, google should provide dozens if not hundreds of examples. google.com/search?q=html+textbox+onchange May 29, 2018 at 11:05

1 Answer 1

0

Ok, First, You need to do something, show some code or anything else, otherwise, nobody could help you because is your homework and that's not correct.

Second, take a look on this:

https://www.w3schools.com/jsref/event_onchange.asp

That's an example how to use Onchange event in a HTML tag. You also need to take a look on how to add classes or style to a HTML tag using Javascript.

Nothing else I can tell you without doing your work.

Good luck. If you have any doubt, after do something, let me know.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.