title: Laravel return view show message
body: <p>How can I show a message after I return a view in my Controller.</p>
  
  <p>I am using Laravel 5.1.</p>
  
  <pre><code> return view('pr.new', [
        'errorMessageDuration' =&gt; 'error too long',
        'route' =&gt; 'createPr',
        'type' =&gt; 'new',
   ]);
  </code></pre>
  
  <p>I tried to call the message like this:</p>
  
  <pre><code>  @if(session('errorMessageDuration'))
           &lt;div class="alert alert-danger"&gt;
               &lt;a href="#" class="close" data-dismiss="alert" aria-label="close"&gt;&amp;times;&lt;/a&gt;
               {{ session('errorMessageDuration') }}
               {{ Input::get('title') }}
           &lt;/div&gt;
    @endif
  </code></pre>
  
  <p>But it did not work, any ideas?</p>