title: Trying to submit data using put on axios but got 405 method not allowed
body: <p>I'm trying to submit using PUT method in the jquery code</p>
  
  <pre><code>  $('#mainTable td').on('change', function(evt, newValue) {
      var $put_method = $('#user-put-method input').val();
      var $name       = $(this).attr('id');
      var $url        = "&lt;?php echo route('Profile.update', Auth::id()) ?&gt;";
      var data        = {
        '__method': $put_method,
        'name': $name
      };
  
      axios.defaults.headers.common['X-CSRF-TOKEN'] = document.querySelector('meta[name="csrf-token"]').getAttribute('content')
      axios.post($url, data)
        .then(function (response) {
          console.log(response.data);
        })
        .catch(function (error) {
          console.log(error);
        });
    });
  </code></pre>
  
  <p>and the data source for this <code>var $put_method = $('#user-put-method input').val();</code> is from</p>
  
  <pre><code>&lt;div class="" id="user-put-method"&gt;
    {{ method_field('PUT') }}
  &lt;/div&gt;
  </code></pre>
  
  <p>and I have this method to catch the request</p>
  
  <pre><code>public function update(Request $request, $id)
  {
    d($request, $id);
  }
  </code></pre>
  
  <p>and through this route</p>
  
  <pre><code>Route::resource('Profile', 'UserProfileController');
  </code></pre>
  
  <p>But when I look at chrome dev-tool
  I got this message</p>
  
  <pre><code>http://project.dev/Profile/1 405 method not allowed
  </code></pre>
  
  <p>Does anyone encounter or did similar to my problem?</p>