title: Laravel post form without refresh problem
body: <p>I wrote a code to submit a form without page refresh in laravel and here's my codes :</p>
  
  <p>my view : </p>
  
  <pre><code>        &lt;form action="{{ url('/admin/products/new') }}" method="post"&gt;
          {{ csrf_field() }}
  
  
          &lt;div class="form-group row"&gt;
              &lt;label for="example-text-input" class="col-sm-2 col-form-label"&gt;pid&lt;/label&gt;
              &lt;div class="col-sm-10"&gt;
                  &lt;input type="text" id="pid" name="pid" class="form-control" placeholder="مثال : Oil distillation machine" id="name"&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
          &lt;div class="form-group row"&gt;
              &lt;label for="example-text-input" class="col-sm-2 col-form-label"&gt;name&lt;/label&gt;
              &lt;div class="col-sm-10"&gt;
                  &lt;input type="text" id="name" name="name" class="form-control" placeholder="مثال : Oil distillation machine" id="name"&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
  
          &lt;div class="form-group row"&gt;
              &lt;label for="example-text-input" class="col-sm-2 col-form-label"&gt;value&lt;/label&gt;
              &lt;div class="col-sm-10"&gt;
                  &lt;input type="text" id="value" name="value" class="form-control" placeholder="مثال : Oil distillation machine" id="name"&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
  
          &lt;div class="form-group"&gt;
              &lt;button type="submit" id="submit" class="btn btn-primary btn-lg text-center waves-effect waves-light"&gt;ارسال&lt;/button&gt;                                    &lt;/div&gt;
  &lt;/div&gt;
  
  &lt;script type="text/javascript"&gt;
      jQuery(document).ready(function(){
          jQuery('#submit').click(function(e){
              e.preventDefault();
              jQuery.ajaxSetup({
                  headers: {
                      'X-CSRF-TOKEN': $('meta[name="_token"]').attr('content')
                  }
              });
              jQuery.ajax({
                  url: "{{ url('/admin/products/new') }}",
                  method: 'post',
                  data: {
                      name: jQuery('#pid').val(),
                      email: jQuery('#name').val(),
                      subject: jQuery('#value').val(),
                  },
                  success: function(data){
                      jQuery.each(data.errors, function(key, value){
                          jQuery('.alert-danger').show();
                          jQuery('.alert-danger').append('&lt;p&gt;'+value+'&lt;/p&gt;');
                      });
                  }
  
              });
          });
      });
  &lt;/script&gt;
  
  
  &lt;/form&gt;
  </code></pre>
  
  <p>my controller :</p>
  
  <pre><code>    public function add_product_post(Request $request)
      {
          $pid = $request-&gt;pid;
          $name = $request-&gt;name;
          $value = $request-&gt;value;
  
  
  DB::table('product_features')-&gt;insert([
  
              'pid' =&gt; $pid,
              'name' =&gt; $name,
              'value' =&gt; $value
          ]);
  
          return ['message' =&gt; 'success'];
      }
  </code></pre>
  
  <p>my problem is that when i click on submit button i just get a response in blank page  {"message":"success"}</p>
  
  <p>I want to submit my form without any page refreshing.
  What is wrong with my code?
  Thanks</p>