Local Storage
How do I make an local storage?
What is a local storage? How do you make a local storage? This script and codes were developed by Bradley Engelhardt on 13 August 2022, Saturday.
Local Storage - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Local Storage</title> <link rel='stylesheet prefetch' href='https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css'>
</head>
<body> <div class="container"> <br>
<div id="text"> <button class="btn btn-success" id="setStorage">set storage</button>
</div> <br> <button class="btn btn-danger" id="removeStorage">remove storage</button>
</div> <script src='https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.0/jquery.min.js'></script> <script src="js/index.js"></script>
</body>
</html>
Local Storage - Script Codes JS Codes
if(localStorage.getItem('buttonClicked') == 'true'){ $('#setStorage').hide(); $('#text').html("<p>Hey</p>"); }
$('#setStorage').click(function(){ localStorage.setItem('buttonClicked', 'true'); alert("The button was set to clicked and will disappear on refresh!");
})
$('#removeStorage').click(function(){ localStorage.setItem('buttonClicked', 'false'); alert("Button clicked was set to false, the button will reappear on page refresh!");
});
Developer | Bradley Engelhardt |
Username | SquishyAndroid |
Uploaded | August 13, 2022 |
Rating | 3 |
Size | 1,709 Kb |
Views | 20,240 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
Jquery Randomizer | 2,946 Kb |
Codecademy Flipboard | 3,793 Kb |
Giphy API Random Gif Selector | 2,636 Kb |
Playing with slide out drawers | 2,812 Kb |
Embedded video header | 2,670 Kb |
Tip Calculator | 2,915 Kb |
Personal Webpage | 8,067 Kb |
20 Die | 2,944 Kb |
Bootstrap Carousel | 2,215 Kb |
Coin Flip | 2,142 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
Right Click Menu | Anodpixels | 2,252 Kb |
Canvas Background Effect | Sonick | 3,513 Kb |
Two tables and header with jspdf-autotable | Someatoms | 2,245 Kb |
NgEasyModal | Lorenzodianni | 4,159 Kb |
RSW | JordanC | 3,726 Kb |
Gradients | Karpovsystems | 2,394 Kb |
Display properties | Hamzaerbay | 1,886 Kb |
Midterm dry run | Jds317 | 1,649 Kb |
Drag and Drop Quiz | Cgspicer | 3,837 Kb |
A Pen by Matt Popovich | Mpopv | 3,349 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!