# 5 days
bugs.vn/io/kcIIN
# Text
file_download DOWNLOAD FILE
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
    <textarea id="list-sim" style="width: 100%; height: 300px;">

    </textarea>
    <input type="text" id="search" onkeyup="getData()">
    <div id="result"></div>
    <script>
        function getData() {
            let list_data = document.getElementById("list-sim").value.split("\n");
            document.getElementById('result').innerHTML = "";
            let textA = document.getElementById('search').value +'';
            console.log(textA);
            for(let i = 0; i < list_data.length; i++) {
                if((list_data[i]+'').includes(textA)) {
                    genDiv(list_data[i]);
                }
            }
        }

        function genDiv(text) {
            let docu = document.getElementById('result');
            let divSpan = document.createElement('div');
            divSpan.innerHTML += text;
            docu.append(divSpan);
        }
    </script>
</body>
</html>