HTML5 Session Storage

  • Stores data for one session
  • The data is deleted when the browser’s window is closed.

<script>
    sessionStorage.variableName = "value";
    alert(sessionStorage.variableName);
    sessionStorage.removeItem("variableName");
    alert(sessionStorage.variableName);
</script>

Leave a Reply

Your email address will not be published. Required fields are marked *