form submission problem

form submission problem

Hi All,

I am having this strange issue. I have a search form, When the page loads for the first time and user enters search query into form , hits submit the form is submitted successfully and results are returned. Once this first search is over and user wants to input another query and hits submit button and nothing happens. I have checked the logs. The request does go to the server but without any data. No data from form fields gets copied. I have to refresh the whole page in order to get it working again. And this behavior is happening all the time... Please help..

Here's my JQuery/Ajax java script...
<code>

function ajaxSubmit(resourceUrl,targetId) {


    var dataString = 'query='+ jQuery("input#query").val();
    var necte = '&source4='+ jQuery("input#necte").val();
    var hte = '&source1='+ jQuery("input#hte").val();
    var scots = '&source2='+ jQuery("input#scots").val();
    var dsl = '&source3='+ jQuery("input#dsl").val();
       
    dataString = dataString + hte + scots + dsl;

   
    jQuery('#<portlet:namespace/>_divLoading').show();
    doAjaxSubmit(resourceUrl,targetId,dataString);
}

function doAjaxSubmit(resourceUrl,targetId,dataString)
{
    jQuery.ajax({
        url: resourceUrl,
        type: 'POST',
        dataType: 'html',
        data: dataString,

      
        error: function(XMLHttpRequest, textStatus, errorThrown){
            alert('Error loading html document: textStatus: '+textStatus);
        },
        success: function(html){
            jQuery('#'+targetId).html("<p>" + html + "</p>");
   
        }
    });
}



And here's the function call from HTML:

<input type="submit" name="submit" id="submit" value="Search" onclick="ajaxSubmit('process.jsp','divTarget'); return false;"/>


</code>