I think this code will help you using just Javascript 😉
function copy()
{
var fname = document.getElementById('FName').value;
var lname = document.getElementById('LName').value;
document.getElementById('results').innerHTML = fname +", "+lname;
return false;
}
The “results” is the id of the DIV where your result would be show 😉
solved Need a button that copies info from one div to another [closed]