I can't get this to work in Google chrome. It's supposed to display after being processed by the php file.

here's the javascript

<code>   ajaxRequest.onreadystatechange = function(){
        if(ajaxRequest.readyState == 4){
            var ajaxDisplay = document.getElementById('ajaxDiv');
            ajaxDisplay.innerHTML = ajaxRequest.responseText;
        }
    }
</code>

here's the html/css code

<code>
     <div id='ajaxDiv'><p></p></div>
</code>

Here's the php code.

<code>
    echo "<p style='background:yellow;>Your changes have been saved</p>";
</code>

It will work in Firefox, but not in Chrome.

Any ideas?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.