php + ajax - clearing xmlresponse object

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • somaskarthic
    New Member
    • Aug 2006
    • 60

    php + ajax - clearing xmlresponse object

    Hi

    I'm using ajax in php page. There are two selection box (for state and city).
    If state is selected , its corresponding countries would be populated in city
    selection box. It is working well. But one issue.

    After receiving the xmlresponse from php file , the xmlresponse string is parsed
    and data populated to the selection box. As a next step i need to clear the xmlresponse object. Assigning xmlresponseobje ct = null, is not working.

    Let me know , the method used to clear the xmlresponse string .



    -somaskarthic
  • raji20
    New Member
    • Aug 2006
    • 28

    #2
    Use a random number in the URL this will help you to clear the xmlresponse string

    Code:
     var txtvalue= document.forms.formname.fieldname.value;  
     if ((txtvalue== null) || (txtvalue== "")) return;  
       var ran_unrounded=Math.random()*100000;
       var ran_number=Math.floor(ran_unrounded); 
      var urlUserList = "pageName.php?value=" + escape(txtvalue) + "&s = " +ran_number;
    Raji

    Comment

    Working...