Created
March 29, 2015 22:30
-
-
Save felipegenuino/d5c266f2c97c965c852e to your computer and use it in GitHub Desktop.
Começando com Ajax
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
var xhr = new XMLHttpRequest(); | |
xhr.onreadystatechange = function(){ | |
if(xhr.readyState === 4){ | |
document.getElementById('ajax').innerHTML = xhr.responseText; | |
} | |
}; | |
xhr.open('GET','sidebar.html'); | |
xhr.send(); | |
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<body> | |
<div class="grid-container centered"> | |
<div class="grid-100"> | |
<div class="contained"> | |
<div class="grid-100"> | |
<div class="heading"> | |
<h1>Bring on the AJAX</h1> | |
</div> | |
<div id="ajax"> | |
</div> | |
</div> | |
</div> | |
</div> | |
</div> | |
</body> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment