title: How to fill ajax POST value in a form field?
body: <pre><code>$(document).ready(function() {
    $('#content-area').mouseup(function() {
     var selection = getSelected();
     if(selection &amp;&amp; (selection = new String(selection).replace(/^\s+|\s+$/g,''))){
           $.ajax({
           type: 'POST',
           url : 'check.php',
           data: 'selection=' + encodeURI(selection),
     });
     }
    });
  </code></pre>
  
  <p>Now how do I access the POSTed 'data' and fill a text field in HTML forms. I'm not clicking a button during the ajax post and I want to do it without reloading the entire page. Any help is much much appreciated..</p>