lundi 25 avril 2016

PHP Laravel route resource to get request

I am trying to send a message form and route resource to show by search bar.

But it does not appear, what wrong in my code?

<form method="GET" action="articles/">
            <div id="custom-search-input">
                <div class="input-group col-md-12">
                    <input type="text" name="name">
                    <span class="input-group-btn">
                        <button  class="btn btn-info btn-lg" type="submit">
                            <i class="glyphicon glyphicon-search"></i>
                        </button>
                    </span>
                </div>
            </div>
            </form>

here is route

Route::resource('articles', 'ArticlesController');

here is controller

    public function show($id){

                $article = Article::find($id);

                if(empty($article))

                abort(404);

                return view('articles.show', compact('article'));

        }


from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/1SGk6du
via IFTTT

Aucun commentaire:

Enregistrer un commentaire