title: how to change button text after succes in ajax
body: <p>I want to change button text on success.. I want to change this to accepted after success </p>
  
  <pre><code>    &lt;button type="button" onclick="saveData&lt;?php echo $row1-&gt;id; ?&gt;()"&gt;Accept&lt;/button&gt; 
        &lt;script&gt;
        function saveData&lt;?php echo $rrr-&gt;id; ?&gt;(){
  
        $.ajax({
          type: "POST",
          url: "&lt;?php echo base_url().'home/accept_seller/'. $rrr-&gt;id; ?&gt;",
          data:{},       
          success:function( data )
          {
  
          }
         });
    }
  </code></pre>
  
  <p>
  My function is properly working because i have used alert after success but i dontknow how to chage its text after success. pls help </p>