0

How can one use a text gotten from the user by prompt in the HTML document?

Like, to display a word a user inputed on the webpage. I'm having trouble. Please help

31st Dec 2021, 8:04 PM
Moses Uga
Moses Uga - avatar
6 Answers
+ 3
I simplified the space where you put name in the html and the js, also I made sure that everything is inside onload() I added comments in the code for what I changed https://code.sololearn.com/W0irA143rJiq/?ref=app
31st Dec 2021, 9:13 PM
Lisa
Lisa - avatar
+ 3
It would be more helpful if you *linked* the code. I don't understand why you append the input twice in "mustard"... Anyway ms, put all your code inside the onload function edit: and you would probably want to wait until the user gave input?
31st Dec 2021, 8:32 PM
Lisa
Lisa - avatar
+ 2
How to link your code: 1. Save the code in code playground 2. Edit the question 3. Insert the saved code using + button This way, anyone can see its parts - HTML, CSS and JS - find anything to fix, test and explain you. Now, I have no idea about what's "mustard" element...
31st Dec 2021, 8:45 PM
Emerson Prado
Emerson Prado - avatar
+ 1
Please link your code!
31st Dec 2021, 8:14 PM
Lisa
Lisa - avatar
31st Dec 2021, 8:20 PM
Moses Uga
Moses Uga - avatar
+ 1
Thanks alot Lisa
31st Dec 2021, 9:54 PM
Moses Uga
Moses Uga - avatar