Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Please help- Clicking not working in publish only in preview with html5

Explorer ,
Jul 15, 2017 Jul 15, 2017

With html5 canvas, clicking to go to a frame and play doesn't seem to work when publishing and opening the published file in chrome. Well, any type of clicking code doesn't work really...This happens when using imported images or any graphics and making movie clips out of them.

Code is fine, just using the basic example snippets. The weird thing is, everything works perfect in preview mode when pressing control enter to preview in chrome. But nothing works when publishing and opening the published file. Only displays the canvas but with non working buttons. What is the issue here? Is this a bug in a new update or should I reinstall or what?

3.7K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Explorer , Jul 15, 2017 Jul 15, 2017

After reading about a similar console error here:

javascript - Cross-origin data in HTML5 canvas - Stack Overflow

it seems as you say unless its a web file I need to give chrome a parameter to allow it locally so adding --allow-file-access-from-files in target shortcut of chrome seemed to help. Is this an ok solution?

Translate
LEGEND ,
Jul 15, 2017 Jul 15, 2017

It's common for test movie to work but opening the published file won't work Either put the files on the server they are due to go to, or use the developer tools in your browser to see what error message is being shown in Console/Errors.

In older versions of Animate the most likely culprit was using Spritesheets. Turning that off would fix the local testing.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jul 15, 2017 Jul 15, 2017

Thanks for the reply!

The error in chrome tools console is:

createjs-2015.11.26.min.js:13 Uncaught An error has occurred. This is most likely due to security restrictions on reading canvas pixel data with local or cross-domain images.

So the only way to fix this is uploading all the files somewhere? No other way?

The reason I prefer to publish offline and then refresh the published file in chrome is because its faster than animates preview, because sometimes the preview freezes or takes a while to load when you keep using it back to back and it gets frustrating..

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 15, 2017 Jul 15, 2017

Each time you Test Movie there is a unique ID attached, and it should work in Chrome and another browser. If you Publish, then there is no unique ID, and you may need to clear cache to get the latest version.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jul 15, 2017 Jul 15, 2017
LATEST

After reading about a similar console error here:

javascript - Cross-origin data in HTML5 canvas - Stack Overflow

it seems as you say unless its a web file I need to give chrome a parameter to allow it locally so adding --allow-file-access-from-files in target shortcut of chrome seemed to help. Is this an ok solution?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines