1$.ajax({
2 type: "post",
3 url: "ajax/example.php",
4 data: 'page=' + btn_page,
5 success: function (data) {
6 var a = data;
7 $.ajax({
8 type: "post",
9 url: "example.php",
10 data: 'page=' + a,
11 success: function (data) {
12
13 }
14 error: function (xhr) {
15 console.log(xhr.responseText); //saves alot of time during debugging
16 }
17 });
18 }
19 });
20