Link function blocks gif images

Hi all!

I have implemented the link function of the post https://forum.processing.org/two/discussion/10490/click-through-link and it works well. However whenever I click the back button from the link and I return to the sketch all the gifs (created through the createImg() function) freeze. This doesn't happen with the linking of the createA() function. Why?

Thanks!

Tagged:

Answers

  • Answer ✓

    Can you post an example sketch so we can test this?

    TBH this looks more like a browser quirk rather than anything specifically to do with p5. Issues with JS and browser back are not uncommon....

  • edited July 2016

    From the second link I have found the solution really quickly, I have just added the script in the index.html:

    <script type="text/javascript"> window.onload = function() {}; window.onunload = function(){}; </script>

    and everything works well now, thanks!

Sign In or Register to comment.