Tonight: Front end fabulous, CityVibes! and other apps!
Oct 14: [fort!] Iterate: design and prototypes
Oct 21: [UVic!] Hackathon!
Oct 28: [fort!] Showcase!!!
//omy, what is this doing?!?!?!
for (var i = 0; i < = 69; i++) {
localStorage.setItem('level_star_' + i, '3');
}
window.location.reload();
//how about this one?!
for (var i = 0; i < = 69; i++) {
localStorage.setItem('level_star_' + i, '-1');
}
window.location.reload();
//w3 schools example! http://www.w3schools.com/html/tryit.asp?filename=tryhtml5_webstorage_local_clickcount
<!DOCTYPE html>
<html>
<head>
<script>
function clickCounter() {
if(typeof(Storage) !== "undefined") {
if (localStorage.clickcount) {
localStorage.clickcount = Number(localStorage.clickcount)+1;
} else {
localStorage.clickcount = 1;
}
document.getElementById("result").innerHTML = "You have clicked the button " +
localStorage.clickcount + " time(s).";
} else {
document.getElementById("result").innerHTML = "Sorry, your browser does not
support web storage...";
}
}
</script>
</head>
<body>
<p><button onclick="clickCounter()" type="button">Click me!</button></p>
<div id="result"></div>
<p>Click the button to see the counter increase.</p>
<p>Close the browser tab (or window), and try again, and the counter will continue to count (is not reset).</p>
</body>
</html>
WORKS SO GREAT FOR TEAMS AND COORDINATION!!!!