I need a person who can help me solve this problem.The code below is working well with the post and the php code.
 //Getting the id of a buyer and loop through
    //sending a request to the seller
    $(document).ready(function(){
    $('.buyerRequest').click(function(){
    var id=$(this).attr('id').replace('id_','');
    $.post('SendingOffer.php',{id:id},function(data){
        if(data=="true"){
            $(this).html('<b>Offer Send</b>').css('background','#dce6f1');
            $(this).attr("disabled","disabled");
        }else if(data=="false"){
            alert('You have reached the maximum number you can send todays');
            }
        });
    });
    });
I have tested the php code,that is,if data returned is true output alert box and is working.For instance
if(data=="true"){
        alert(id);
}
However,on including this code
if(data=="true"){
        $(this).html('<b>Offer Send</b>').css('background','#dce6f1');
        $(this).attr("disabled","disabled");
}
and clicking the current id,i am unable to disable it and change it's attributes to offer send.
How can i deal with this problem
This is my div code
echo"<li id='td_request'><a id='id_".$fetch_num['order_id']."' class='buyerRequest' href='#".$fetch_num['order_id']."'>Send Offer</a></li>";
 
     
     
     
    