ReferenceError: scheduler is not defined

Hello!

I am trying to use Read-only mode for the entire lightbox. I have managed to make it work locally but when I try to do the same in server I get the error :

Uncaught ReferenceError: scheduler is not defined dhtmlxscheduler_readonly.js:151(anonymous function)

I have added htmlxscheduler_readonly.js like this :

and also I have used the command scheduler.config.readonly_form = true;

the path is correct because I am using the same variable {{STATIC_HOME}} for :

thank you very much,
Maria

You included the dhtmlxscheduler_readonly.js after the dhtmlxscheduler.js?

Which error would occur if you delete the include line of the dhtmlxscheduler_readonly.js?

I would guess that your path of the dhtmlxscheduler.js is wrong, or did you changed the folder-architecture on your own???

By default it is

calendarColor/codesbase/dhtmlxscheduler.js and
calendarColor/codebase/ext/dhtmlxscheduler_readonly.js

I changed the folder-architecture on my own but thank you! You find the problem I should have added like :

    <script src="{{ STATIC_HOME }}/calendarColor/dhtmlxscheduler.js" type="text/javascript" charset="utf-8"></script>

Now it is working!
Thank you very much
Maria

Perfect :slight_smile: Allways a pleasure to help pther one’s, because i also have a lot of questions and problems with my own project :slight_smile: