1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

AJAX passing statechanged variables

Discussion in 'Software Development' started by scrubbicus, Dec 13, 2009.

Thread Status:
Not open for further replies.
  1. scrubbicus

    scrubbicus Thread Starter

    Jan 23, 2009
    So I'm having a difficult time passing statechanged a variable to tell it where to put my responseText, I've tried alot so I'm thinking that I can't do it that way but I figure there must be a way to tell xmlhttp where to write the resposeText when the readystate hits 4.

    This is what I have

    xmlhttp.onreadystatechange stateChanged;

    stateChanged() {
    xmlhttp.readyState == ) {
      } else if( 
    xmlhttp.readyState == ) {
    I tried

    xmlhttp.onreadystatechange stateChangedelementID );
    then just accepted it on stateChanged() and using it in the getElementById
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/885299

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice