Advertisement
Guest User

Untitled

a guest
May 26th, 2016
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. <a href="javascript:void(0)" onclick="amount_pay('{{ $res->id}}');"><i class="fa fa-pencil-square-o"></i></a>
  2.  
  3. <script>
  4.  
  5. function amount_pay(id)
  6. {
  7. $.ajax({
  8. type: 'POST',
  9. url: 'amount_popup/'+ id,// calling the file with id
  10.  
  11. success: function (data) {
  12. alert(1);
  13. }
  14. });
  15. }
  16. </script>
  17.  
  18. Route::post('amount_popup/{id}', 'AdminControllerAmountController@amount_to_pay');
  19.  
  20. public function amount_to_pay($id)
  21. {
  22. echo $id;
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement