Laravel Getting Error when ajax requesting Im sending files along with lots of form content with added dynamaticlly
Route::group(['as'=>'employee.', 'prefix' => 'employee', 'namespace'=>'Employee', 'middleware' => ['auth', 'employee']], function(){
Route::post('profile/updateProfile', [App\Http\Controllers\Employee\ProfileController::class, 'updateProfile'])->name('updateProfile'); });
Ajax Request look like
$.ajax({
type:'POST',
url: '',
headers: {'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')},
type: 'POST',
contentType: false,
processData: false,
cache: false,
data: fm,
success: function(responce) {
console.log(responce);
},
error: function(err) {
console.log(err);
},
});
**Controller For **
public function updateProfile(Request $request)
{
dd('IN Profile Controller');
// return response()->json("Profile Controller");
}
from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/2KBBd6Q
via IFTTT
Aucun commentaire:
Enregistrer un commentaire