Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- views>restaurant>index.blade.php.
- web.php
- Route::resource('restaurant/id','restaurantController');
- index (ajax)
- $('.modal-footer').on('click', '.edit', function() {
- $.ajax({
- type: 'post',
- url: 'restaurant/id',
- data: {
- '_token': $('input[name=_token]').val(
- controller.
- public function update(Request $req,$id) {
- $data = ipData::find($id);
- $data->first_name = $req->get('fname');
- $data->last_name = $req->get('lname');
- $data->save();
- return response ()->json ( $data );
- }
- data and modal windows popup working fine…. but Update and Delete action’s isn’t working maybe because i have folder after view. Please help me. stress a lot. XD
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement