Что вызывает «Uncaught ReferenceError: Plotly не определен»?Php

Кемеровские программисты php общаются здесь
Ответить
Anonymous
 Что вызывает «Uncaught ReferenceError: Plotly не определен»?

Сообщение Anonymous »


New to plotly.js and trying to get it working on a WordPress page in a custom form using PHP and JavaScript. I enqueue the script, and I have confirmed it is being loaded when the page loads. I then setup the data and layout for the chart (this part was working on another page on a different site). But the debugger in Firefox shows the message “Uncaught ReferenceError: Plotly is not defined” on the line where the chart is instantiated.

Plotly.newPlot('#myChart', data, layout, config);\n";

I’ve tried loading the plotly js file from the CDN and from the site itself, with no difference in results.

I’m using “/forms/js/plotly-2.29.1.min.js”, and I have confirmed it is being loaded without errors in the debugger.


Источник: https://stackoverflow.com/questions/781 ... ot-defined
Ответить

Быстрый ответ

Изменение регистра текста: 
Смайлики
:) :( :oops: :roll: :wink: :muza: :clever: :sorry: :angel: :read: *x)
Ещё смайлики…
   
К этому ответу прикреплено по крайней мере одно вложение.

Если вы не хотите добавлять вложения, оставьте поля пустыми.

Максимально разрешённый размер вложения: 15 МБ.

Вернуться в «Php»