0

Only value enter in first box is displayed , how value of secong box also can be seen on same page

I want to create a form which ask for book and author name , and as click on submit it will display both value in same webpage.. I was able to do it with only one box and both of them.. Please guide how to do it https://code.sololearn.com/W86lm6sq4djK/?ref=app

16th Feb 2020, 10:37 AM
Prateek Kumar Agarwal
Prateek Kumar Agarwal - avatar
8 Answers
+ 1
https://code.sololearn.com/Wt1maTxsKqMu/?ref=app
16th Feb 2020, 10:46 AM
CalviŐ˛
CalviŐ˛ - avatar
+ 1
onclick="bookInput();authorInput();"
16th Feb 2020, 12:04 PM
Gordon
Gordon - avatar
0
CalviŐ˛ Okay after going to function of book, it doesn't goes to function of author... That's why it doesn't print... correct me if am wrong?
16th Feb 2020, 10:49 AM
Prateek Kumar Agarwal
Prateek Kumar Agarwal - avatar
0
Prateek Kumar Agarwal you got to call the function in order to run it. And you also need to set the element of author id.
16th Feb 2020, 12:04 PM
CalviŐ˛
CalviŐ˛ - avatar
0
Gordon Okay this also wrong..
16th Feb 2020, 2:40 PM
Prateek Kumar Agarwal
Prateek Kumar Agarwal - avatar
0
CalviŐ˛ also need to set element of author Id? Can you explain it please
16th Feb 2020, 2:42 PM
Prateek Kumar Agarwal
Prateek Kumar Agarwal - avatar
0
Prateek Kumar Agarwal It obviously your html code does not have element with author id. How could the authorinput() update it? Please study the code i shared. And also complete your html course and start learning css and javascript to understand the fundamentals of the web languages first.
17th Feb 2020, 12:56 AM
CalviŐ˛
CalviŐ˛ - avatar
0
CalviŐ˛ Ok.. thanks
17th Feb 2020, 8:34 AM
Prateek Kumar Agarwal
Prateek Kumar Agarwal - avatar