Advertisement
Guest User

Untitled

a guest
Jun 28th, 2017
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function loadXMLDoc(link) {
  2.     if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari
  3.         xmlhttp=new XMLHttpRequest();
  4.     }
  5.     else {// code for IE6, IE5
  6.         xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
  7.     }
  8.     xmlhttp.onreadystatechange=function() {
  9.         if (xmlhttp.readyState==4 && xmlhttp.status==200) {
  10.             document.getElementById("content").innerHTML=xmlhttp.responseText;
  11.         }
  12.     }
  13.     xmlhttp.open("GET",link,true);
  14.     xmlhttp.send();
  15. }
  16. function loadTag(tag) {
  17.     if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari
  18.         xmlhttp=new XMLHttpRequest();
  19.     }
  20.     else {// code for IE6, IE5
  21.         xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
  22.     }
  23.  
  24.     xmlhttp.onreadystatechange=function() {
  25.         if (xmlhttp2.readyState==4 && xmlhttp.status==200) {
  26.             document.getElementById("tags").innerHTML=xmlhttp.responseText;
  27.     }
  28.     xmlhttp.open("GET", tag, true);
  29.     xmlhttp.send();
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement