2 years ago

Live search AJAX without JQUERY

Posted 2 years ago by mturner20

I am trying to do a live search using AJAX, but without JQUERY. I have set up my route, controller, and view. Need some help with the next steps I should be taking. I have it spitting out json data and also have a javascript file calling to the method

    $users = DB::select('SELECT * FROM users');
    return Response::json($users);

Route::get('welcome' ,'[email protected]');

        <div class="container">
            <div class="content">
                <div class="title">Game of Thrones Directory</div>
                    <h1> Game of Thrones Directory </h1>
                <label for="searchbox">Search:</label>
                <input type="text" name="search" id="searchbox" placeholder="Start your search here">
            <div id="txtHint">Search Results here.</div>
            <div id="maindiv"></div>

Please sign in or create an account to participate in this conversation.