CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 2009
    Posts
    160

    onreadystatechange

    Below in my code i wish to understand the role of onreadystatechange called with the xmlhttp object. i read on the web that it gets a value from 1 to 4 ranging on the status of the process but my question is we still havent opened the connection and sent the object to the server (open, send) which follows this statement so how do we know the value.....

    and also statechange 's address is being assigned to the object so its working as a function pointer and thus there is no ().... am i correct?


    Code:
    var url="get_user.php";
    url=url+"?q="+str;
    url=url+"&sid="+Math.random();
    xmlhttp.onreadystatechange=stateChanged;
    xmlhttp.open("GET",url,true);
    xmlhttp.send(null);

  2. #2
    Join Date
    May 2002
    Posts
    10,943

    Re: onreadystatechange

    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured