Answers for "how to set paragraph tag on input"

0

how to set paragraph tag on input

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <input type="text" id="input">
<p id="demo"></p>
</body>
<script>
    let a = document.getElementById("input")
    document.getElementById("demo").innerHTML = a
</script>
</html>
Posted by: Guest on August-07-2021

Browse Popular Code Answers by Language