I'm rather new to javascript and was wondering how a few things were made.
1. How do you place text in a <textarea> when you press a button? (I know u have to do something.value but won't that replace it instead of add text?)
2. How do you place text into a <textarea> when alt + letter are pressed?
3. How do you change the text in a button when it is pressed?
4. If i have a disabled button, how would i enable it only if certain fields were entered? (similarly how would i automatically write text if two fields don't match?)
I'd greatly appreciate it if anybody can answer my questions or give me links to where I can read about how to do these effects.
Question
Sir Rugmuncher
I'm rather new to javascript and was wondering how a few things were made.
1. How do you place text in a <textarea> when you press a button? (I know u have to do something.value but won't that replace it instead of add text?)
2. How do you place text into a <textarea> when alt + letter are pressed?
3. How do you change the text in a button when it is pressed?
4. If i have a disabled button, how would i enable it only if certain fields were entered? (similarly how would i automatically write text if two fields don't match?)
I'd greatly appreciate it if anybody can answer my questions or give me links to where I can read about how to do these effects.
Thanks
Link to comment
Share on other sites
2 answers to this question
Recommended Posts