Answers for "how to pass laravel route name to ajax request"

0

how to pass laravel route name to ajax request

var id= $("input[name=editId]").val();
$.ajax({
   type:'POST',
   enctype: 'multipart/form-data',
   url:"{{ route('updateArticle') }}" + '/' + id,
   data: formdata,
   contentType: false,
   processData: false,
   success:function(data){
        $('.alert-success').html(data.success).fadeIn('slow');
        $('.alert-success').delay(3000).fadeOut('slow');
   }
});
Posted by: Guest on July-30-2021

Code answers related to "how to pass laravel route name to ajax request"

Code answers related to "Javascript"

Browse Popular Code Answers by Language