I am still in the same problem in this link here. So, I used the append
method. And here is the AJAX
code:
[1] Why are you catching value
of a button
var selectW = $('#insert_new').val();
I think there is no need for that.
[2] Add this before ajax
call
dataString = 'selectW='+ selectW + '&select_at='+ select_at + '&pay='+ pay+ '&facture='+facture+ '&select_opt='+ select_opt;
[3] In ajax
call set `data' as
data: dataString,
instead of
data: {'text': insert_new, 'text': selectW, 'text': select_at, 'text': pay, 'text': facture, 'text': select_opt},
[4] Why are you catching response
, you are not sending any string
back from insert_buy.php
if(response=="success")
{
as you are not getting return value
as "success"
, else
part is getting executed and getting alert
message as "No data added".