Commit 61b78aa1 61b78aa1dde19702bbece9b556e6c456713a7ba1 by Adnan Ahmad

Update jquery.js

1 parent 37843215
...@@ -72,7 +72,7 @@ $(document).ready(function(){ ...@@ -72,7 +72,7 @@ $(document).ready(function(){
72 // get data from database through ajax 72 // get data from database through ajax
73 $.ajax({ 73 $.ajax({
74 type:'GET', 74 type:'GET',
75 url: '/Assignment/get.php', 75 url: '/Assignments/get.php',
76 success: function (data){ 76 success: function (data){
77 items = JSON.parse(data); 77 items = JSON.parse(data);
78 //console.log(items); 78 //console.log(items);
...@@ -173,7 +173,7 @@ $('#item_form').on('submit', function (e) { ...@@ -173,7 +173,7 @@ $('#item_form').on('submit', function (e) {
173 data = new FormData(document.getElementById('item_form')); 173 data = new FormData(document.getElementById('item_form'));
174 $.ajax({ 174 $.ajax({
175 type: 'POST', 175 type: 'POST',
176 url: '/Assignment/database.php', 176 url: '/Assignments/database.php',
177 data: data, 177 data: data,
178 cache: false, 178 cache: false,
179 processData: false, 179 processData: false,
...@@ -191,7 +191,7 @@ $('#item_form').on('submit', function (e) { ...@@ -191,7 +191,7 @@ $('#item_form').on('submit', function (e) {
191 id = $(this).attr('value'); 191 id = $(this).attr('value');
192 $.ajax({ 192 $.ajax({
193 type:'POST', 193 type:'POST',
194 url: '/Assignment/get.php', 194 url: '/Assignments/get.php',
195 data:{'id':id}, 195 data:{'id':id},
196 datatype: 'JSON', 196 datatype: 'JSON',
197 success: function (data){ 197 success: function (data){
...@@ -213,7 +213,7 @@ $('#item_form').on('submit', function (e) { ...@@ -213,7 +213,7 @@ $('#item_form').on('submit', function (e) {
213 if(confirm('Are you sure you want to delete this?')){ 213 if(confirm('Are you sure you want to delete this?')){
214 $.ajax({ 214 $.ajax({
215 type:'POST', 215 type:'POST',
216 url: '/Assignment/database.php', 216 url: '/Assignments/database.php',
217 data:{'id':id, 'action':action}, 217 data:{'id':id, 'action':action},
218 success: function (info){ 218 success: function (info){
219 alert(info); 219 alert(info);
......