Write basic AJAX search functionality