Tutu
from search data var datas = $("entry", xmlResponse).map(function () { return { title: $("title", this).text(), content: $("content", this).text(), url: $("url", this).text() }; }).get(); var $input = document.getElementById(search_id); var $resultContent = document.getElementById(content_id); $input.addEventListener('input', function () { var str = '"; $resultContent.innerHTML = str; }); } }); }; searchFunc('/search.xml', 'searchInput', 'searchResult'); });