0
Multiple textbox copy on single click
Hi there I’m trying to copy text from two different text boxes from on copy button. var copytxt1 = document.getElementById('copy1'); var copytxt2 = document.getElementById('copy2'); copytxt1.select(); // How can I put copytxt2 in the same line so I can copy same time. Please see what I tried and thought it would work https://code.sololearn.com/W87wkD3FQ7th/?ref=app
1 Antwort
0
Firstly I noticed you are trying to copy from your input box which is wrong.
Do this
Create a div, that the values being inputed on the input box goes to, then you can copy from that box, that should work fine