Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QBJS on a webpage?
#10
(04-23-2025, 05:31 AM)SMcNeill Wrote: ...
Quote:After some research, I suspect that the issue arises due to the sketch being contained in an <iframe> Tag (preview.p5js.org) and the local storage object being stored in the browser under that subdomain. The local storage being cleared after a browser reset is likely a WebKit security measure to prevent third party tracking ("Intelligent Tracking Prevention" https://webkit.org/blog/7675/intelligent...revention/). One solution could be to store and access the local storage object under the domain editor.p5js.org. But this exceeds the scope of my understanding.

Note 2: Safari and iPad erases *all* browser storage after seven days of it being unvisited.  That's another of their security features they pushed on the public a while back to protect us all from ourselves.  /sigh.   Makes a real PITA with some of the html5 browser games.  Take a break, start over...

This is why we can't have nice things!

I typically don't use local storage for anything too important, user preferences, things like that.  In the example above it was just being used as a simple mechanism for communication between different QBJS apps that have been included into a parent page via iframes.  You can actually see that the storage value is cleared each time the page is loaded.
Reply


Messages In This Thread
QBJS on a webpage? - by James D Jarvis - 04-19-2025, 12:55 PM
RE: QBJS on a webpage? - by dbox - 04-19-2025, 08:22 PM
RE: QBJS on a webpage? - by James D Jarvis - 04-20-2025, 01:13 AM
RE: QBJS on a webpage? - by dbox - 04-21-2025, 01:54 PM
RE: QBJS on a webpage? - by James D Jarvis - 04-22-2025, 12:50 AM
RE: QBJS on a webpage? - by dbox - 04-22-2025, 07:47 PM
RE: QBJS on a webpage? - by SMcNeill - 04-22-2025, 08:30 PM
RE: QBJS on a webpage? - by dbox - 04-22-2025, 10:08 PM
RE: QBJS on a webpage? - by SMcNeill - 04-23-2025, 05:31 AM
RE: QBJS on a webpage? - by dbox - 04-23-2025, 05:20 PM

Forum Jump:


Users browsing this thread: 2 Guest(s)