Answers for "javascript refresh element"

84

refresh window js

window.location.reload();
Posted by: Guest on April-05-2020
1

relode div

function updateDiv()
{ 
    $( "#here" ).load(window.location.href + " #here" );
}
Posted by: Guest on April-22-2020
2

refresh javascript

location.reload();
Works like refresh button.
Posted by: Guest on January-07-2021
-1

js refresh element

document.getElementById("youriframeid").contentWindow.location.reload(true);
Posted by: Guest on August-14-2021
-1

javascript replace element

<html>
<head>
</head>
<body>
  <div>
    <a id="myAnchor" href="http://www.stackoverflow.com">StackOverflow</a>
  </div>
<script type="text/JavaScript">
  var myAnchor = document.getElementById("myAnchor");
  var mySpan = document.createElement("span");
  mySpan.innerHTML = "replaced anchor!";
  myAnchor.parentNode.replaceChild(mySpan, myAnchor);
</script>
</body>
</html>
Posted by: Guest on January-07-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language